diff options
| author | Jim Meyering | 2011-06-22 14:23:17 +0200 |
|---|---|---|
| committer | Jim Meyering | 2011-06-22 14:23:17 +0200 |
| commit | d5a19415d0bc308557d754e4438a2656e16bb0ab (patch) | |
| tree | f96b16e5ec30d372170fd0602b26014bb7dc9553 /src | |
| parent | 130e3e112121f9f27514ddd4fee6d11fb0fed0b3 (diff) | |
| download | emacs-d5a19415d0bc308557d754e4438a2656e16bb0ab.tar.gz emacs-d5a19415d0bc308557d754e4438a2656e16bb0ab.zip | |
don't leak an XBM-image-sized buffer
* image.c (xbm_load): Free the image buffer after using it.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/image.c | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 48625bbf285..571979ea132 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2011-06-22 Jim Meyering <meyering@redhat.com> | ||
| 2 | |||
| 3 | don't leak an XBM-image-sized buffer | ||
| 4 | * image.c (xbm_load): Free the image buffer after using it. | ||
| 5 | |||
| 1 | 2011-06-21 Paul Eggert <eggert@cs.ucla.edu> | 6 | 2011-06-21 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 7 | ||
| 3 | Port to Sun C. | 8 | Port to Sun C. |
diff --git a/src/image.c b/src/image.c index 495bfdc0eef..802568101ea 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -2829,6 +2829,7 @@ xbm_load (struct frame *f, struct image *img) | |||
| 2829 | } | 2829 | } |
| 2830 | 2830 | ||
| 2831 | success_p = xbm_load_image (f, img, contents, contents + size); | 2831 | success_p = xbm_load_image (f, img, contents, contents + size); |
| 2832 | xfree (contents); | ||
| 2832 | } | 2833 | } |
| 2833 | else | 2834 | else |
| 2834 | { | 2835 | { |