diff options
| author | Chris Peterson <cpeterson@mozilla.com> | 2014-05-29 02:04:06 (GMT) |
|---|---|---|
| committer | Jason Evans <jasone@canonware.com> | 2014-06-02 14:51:33 (GMT) |
| commit | 3e310b34eb53eb331981ecda2ea5f10cf6956747 (patch) | |
| tree | f1d386a84b8894021f34071263e180a9c8f21ca3 | |
| parent | 94ed6812bc04a6171d1a801f2740355f458d5c9c (diff) | |
| download | jemalloc-3e310b34eb53eb331981ecda2ea5f10cf6956747.zip jemalloc-3e310b34eb53eb331981ecda2ea5f10cf6956747.tar.gz jemalloc-3e310b34eb53eb331981ecda2ea5f10cf6956747.tar.bz2 | |
Fix -Wsign-compare warnings
| -rw-r--r-- | src/prof.c | 4 | ||||
| -rw-r--r-- | src/util.c | 4 |
2 files changed, 4 insertions, 4 deletions
@@ -1093,7 +1093,7 @@ label_open_close_error: #define DUMP_FILENAME_BUFSIZE (PATH_MAX + 1) #define VSEQ_INVALID UINT64_C(0xffffffffffffffff) static void -prof_dump_filename(char *filename, char v, int64_t vseq) +prof_dump_filename(char *filename, char v, uint64_t vseq) { cassert(config_prof); @@ -1101,7 +1101,7 @@ prof_dump_filename(char *filename, char v, int64_t vseq) if (vseq != VSEQ_INVALID) { /* "<prefix>.<pid>.<seq>.v<vseq>.heap" */ malloc_snprintf(filename, DUMP_FILENAME_BUFSIZE, - "%s.%d.%"PRIu64".%c%"PRId64".heap", + "%s.%d.%"PRIu64".%c%"PRIu64".heap", opt_prof_prefix, (int)getpid(), prof_dump_seq, v, vseq); } else { /* "<prefix>.<pid>.<seq>.<v>.heap" */ @@ -100,7 +100,7 @@ uintmax_t malloc_strtoumax(const char *restrict nptr, char **restrict endptr, int base) { uintmax_t ret, digit; - int b; + unsigned b; bool neg; const char *p, *ns; @@ -548,7 +548,7 @@ malloc_vsnprintf(char *str, size_t size, const char *format, va_list ap) assert(len == '?' || len == 'l'); assert_not_implemented(len != 'l'); s = va_arg(ap, char *); - slen = (prec < 0) ? strlen(s) : prec; + slen = (prec < 0) ? strlen(s) : (size_t)prec; APPEND_PADDED_S(s, slen, width, left_justify); f++; break; |
