diff options
| author | Paul Eggert | 2019-04-20 23:10:37 -0700 |
|---|---|---|
| committer | Paul Eggert | 2019-04-20 23:10:57 -0700 |
| commit | 3f90aa7eec8909d6e4501dcd551665981b6b09af (patch) | |
| tree | 7d91be978b0446359b44b4bfc39152d48ee4eed7 /lib-src | |
| parent | 515f57826f5cc2d85232f0d897d0e02a069667db (diff) | |
| download | emacs-3f90aa7eec8909d6e4501dcd551665981b6b09af.tar.gz emacs-3f90aa7eec8909d6e4501dcd551665981b6b09af.zip | |
Port make-fingerprint to LeakSanitizer
* lib-src/make-fingerprint.c (buf): Now static,
to pacify LeakSanitizer.
Diffstat (limited to 'lib-src')
| -rw-r--r-- | lib-src/make-fingerprint.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib-src/make-fingerprint.c b/lib-src/make-fingerprint.c index 38a33576148..79bd007a5f9 100644 --- a/lib-src/make-fingerprint.c +++ b/lib-src/make-fingerprint.c | |||
| @@ -57,6 +57,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 57 | #endif | 57 | #endif |
| 58 | #endif /* WINDOWSNT */ | 58 | #endif /* WINDOWSNT */ |
| 59 | 59 | ||
| 60 | /* Static (instead of being local to 'main') to pacify LeakSanitizer. */ | ||
| 61 | static char *buf; | ||
| 62 | |||
| 60 | int | 63 | int |
| 61 | main (int argc, char **argv) | 64 | main (int argc, char **argv) |
| 62 | { | 65 | { |
| @@ -111,7 +114,7 @@ main (int argc, char **argv) | |||
| 111 | return EXIT_FAILURE; | 114 | return EXIT_FAILURE; |
| 112 | } | 115 | } |
| 113 | 116 | ||
| 114 | char *buf = malloc (st.st_size + 1); | 117 | buf = malloc (st.st_size + 1); |
| 115 | if (!buf) | 118 | if (!buf) |
| 116 | { | 119 | { |
| 117 | perror ("malloc"); | 120 | perror ("malloc"); |