From: Michael Stapelberg Date: Fri, 16 May 2014 16:03:31 +0000 (+0200) Subject: use size_t for strspn() return value X-Git-Tag: 4.8~38 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=e41b11fa0a26de479bc2843682aaf2d383e8032b;p=i3%2Fi3 use size_t for strspn() return value --- diff --git a/i3bar/src/workspaces.c b/i3bar/src/workspaces.c index ee2112fe..e89af4f6 100644 --- a/i3bar/src/workspaces.c +++ b/i3bar/src/workspaces.c @@ -115,7 +115,7 @@ static int workspaces_string_cb(void *params_, const unsigned char *val, size_t snprintf(ws_num, sizeof(ws_num), "%d", params->workspaces_walk->num); /* Calculate the length of the number str in the name */ - int offset = strspn(ws_name, ws_num); + size_t offset = strspn(ws_name, ws_num); /* Also strip off the conventional ws name delimiter */ if (offset && ws_name[offset] == ':')