diff options
| author | Junio C Hamano <gitster@pobox.com> | 2018-08-15 15:08:25 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2018-08-15 15:08:25 -0700 |
| commit | 7d020f5a78a1ae7ff47d65a2adc79171c0cf9cb7 (patch) | |
| tree | 5196c1aa277fe6619a24b9f5607f062f20f68b2e /utf8.h | |
| parent | bce8031d9a1ff3b791f9e4c1cd1e5634faaf55fb (diff) | |
| parent | 7726d360b5ba859ae2b6ceefc5d88cc518c78063 (diff) | |
Merge branch 'jk/size-t'
Code clean-up to use size_t/ssize_t when they are the right type.
* jk/size-t:
strbuf_humanise: use unsigned variables
pass st.st_size as hint for strbuf_readlink()
strbuf_readlink: use ssize_t
strbuf: use size_t for length in intermediate variables
reencode_string: use size_t for string lengths
reencode_string: use st_add/st_mult helpers
Diffstat (limited to 'utf8.h')
| -rw-r--r-- | utf8.h | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -25,14 +25,14 @@ void strbuf_utf8_replace(struct strbuf *sb, int pos, int width, #ifndef NO_ICONV char *reencode_string_iconv(const char *in, size_t insz, - iconv_t conv, int *outsz); -char *reencode_string_len(const char *in, int insz, + iconv_t conv, size_t *outsz); +char *reencode_string_len(const char *in, size_t insz, const char *out_encoding, const char *in_encoding, - int *outsz); + size_t *outsz); #else -static inline char *reencode_string_len(const char *a, int b, - const char *c, const char *d, int *e) +static inline char *reencode_string_len(const char *a, size_t b, + const char *c, const char *d, size_t *e) { if (e) *e = 0; return NULL; } #endif |
