Fix clang warnings about converting size_t to int and back again 08/9208/1
authorAlan Coopersmith <alan.coopersmith@oracle.com>
Tue, 15 Jan 2013 07:21:43 +0000 (23:21 -0800)
committerSung-Jin Park <sj76.park@samsung.com>
Tue, 3 Sep 2013 03:32:31 +0000 (23:32 -0400)
commitb5d4fbbbec372bd3aa43afa405421a21146e7a53
treee7fee8cced75f61bf1acf13cd173cadf623c7deb
parentdbcf0699fa27c6966029939fc18490edfcf5eaff
Fix clang warnings about converting size_t to int and back again

xev.c:909:15: warning: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
    int len = strlen (s);
        ~~~   ^~~~~~~~~~
xev.c:917:34: warning: implicit conversion changes signedness: 'int' to 'size_t' (aka 'unsigned long') [-Wsign-conversion]
    if (strncmp (s, "notuseful", len) == 0) return (NotUseful);
        ~~~~~~~                  ^~~
xev.c:918:35: warning: implicit conversion changes signedness: 'int' to 'size_t' (aka 'unsigned long') [-Wsign-conversion]
    if (strncmp (s, "whenmapped", len) == 0) return (WhenMapped);
        ~~~~~~~                   ^~~
xev.c:919:31: warning: implicit conversion changes signedness: 'int' to 'size_t' (aka 'unsigned long') [-Wsign-conversion]
    if (strncmp (s, "always", len) == 0) return (Always);
        ~~~~~~~               ^~~

Change-Id: Ie275dd4b1ca2e3b25ad12176c189f981f635450f
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
xev.c