diff options
| author | Gerd Moellmann | 2000-07-21 14:33:35 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-07-21 14:33:35 +0000 |
| commit | 017f053958aa10e4d25edc5a327c61cdd8e16c23 (patch) | |
| tree | 4a67352d6adeee13c9cd5c754eea69294902d835 /src/buffer.c | |
| parent | 43e764c95217460e5cf610faea80ff386f541183 (diff) | |
| download | emacs-017f053958aa10e4d25edc5a327c61cdd8e16c23.tar.gz emacs-017f053958aa10e4d25edc5a327c61cdd8e16c23.zip | |
(Fprevious_overlay_change): Avoid memory leak.
Diffstat (limited to 'src/buffer.c')
| -rw-r--r-- | src/buffer.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/buffer.c b/src/buffer.c index e7f6db096fd..120392cebba 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -3613,14 +3613,14 @@ If there are no more overlay boundaries before POS, return (point-min).") | |||
| 3613 | 3613 | ||
| 3614 | CHECK_NUMBER_COERCE_MARKER (pos, 0); | 3614 | CHECK_NUMBER_COERCE_MARKER (pos, 0); |
| 3615 | 3615 | ||
| 3616 | len = 10; | ||
| 3617 | overlay_vec = (Lisp_Object *) xmalloc (len * sizeof (Lisp_Object)); | ||
| 3618 | |||
| 3619 | /* At beginning of buffer, we know the answer; | 3616 | /* At beginning of buffer, we know the answer; |
| 3620 | avoid bug subtracting 1 below. */ | 3617 | avoid bug subtracting 1 below. */ |
| 3621 | if (XINT (pos) == BEGV) | 3618 | if (XINT (pos) == BEGV) |
| 3622 | return pos; | 3619 | return pos; |
| 3623 | 3620 | ||
| 3621 | len = 10; | ||
| 3622 | overlay_vec = (Lisp_Object *) xmalloc (len * sizeof (Lisp_Object)); | ||
| 3623 | |||
| 3624 | /* Put all the overlays we want in a vector in overlay_vec. | 3624 | /* Put all the overlays we want in a vector in overlay_vec. |
| 3625 | Store the length in len. | 3625 | Store the length in len. |
| 3626 | prevpos gets the position of the previous change. */ | 3626 | prevpos gets the position of the previous change. */ |