From: Matthew Fernandez Date: Tue, 9 Nov 2021 02:45:41 +0000 (-0800) Subject: font_in_list_permissive: squash -Wsign-conversion warning X-Git-Tag: 2.50.0~33^2~5 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a92055ee43b649679d42b192832fceeee19cf7d9;p=graphviz font_in_list_permissive: squash -Wsign-conversion warning The preceding logic guarantees this value will be non-negative. --- diff --git a/lib/common/textspan_lut.c b/lib/common/textspan_lut.c index 9ad9cf6dd..77977576f 100644 --- a/lib/common/textspan_lut.c +++ b/lib/common/textspan_lut.c @@ -745,7 +745,8 @@ static bool font_in_list_permissive(const char *value, const char *list) { do { const char *next_pipe = strchr(list, '|'); - size_t next_pipe_or_end_pos = next_pipe ? next_pipe - list : strlen(list); + size_t next_pipe_or_end_pos = + next_pipe ? (size_t)(next_pipe - list) : strlen(list); if (font_name_equal_permissive(value, list, next_pipe_or_end_pos)) { return true; }