On Sunday 2017-08-27 Will Storey wrote : > static void > concat_width (struct sbuf *buf, char *s, int width)
I would turn this to const char *s > + int i = 0; > + /* The size of a character in bytes. */ > + int char_len = 0; > + /* Index of the current character in the string. */ > + int char_idx = 0; These should be size_t . > + /* Invalid character? */ > + if (char_len == -1) > + break; if (char_len == (size_t) -1) + + /* Null character? */ + if (char_len == 0) + break; Don't we need to check for the case when the return value is (size_t) -2 ? _______________________________________________ Ratpoison-devel mailing list Ratpoison-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/ratpoison-devel