util: Changes to 'master'

Alan Coopersmith alanc at kemper.freedesktop.org
Sun Dec 16 15:29:44 PST 2012


 ucs2any.c |   24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

New commits:
commit aba5a2f22ff6e0ada7d606cbf91c5974e3255d77
Author: Alan Coopersmith <alan.coopersmith at oracle.com>
Date:   Sun Dec 16 15:27:33 2012 -0800

    Fix a bunch of clang integer size conversion warnings in ucs2any
    
    ucs2any.c:149:36: warning: implicit conversion changes signedness: 'int' to 'si
    ze_t' (aka 'unsigned long') [-Wsign-conversion]
            *dest = zrealloc(*dest, dest_size + source_size);
                    ~~~~~~~~        ~~~~~~~~~~^~~~~~~~~~~~~
    ucs2any.c:147:29: warning: implicit conversion loses integer precision: 'unsign
    ed long' to 'int' [-Wshorten-64-to-32]
                    dest_size = strlen(*dest) + 1;
                              ~ ~~~~~~~~~~~~~~^~~
    ucs2any.c:148:16: warning: implicit conversion loses integer precision: 'size_t
    ' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
            source_size = strlen(source);
                        ~ ^~~~~~~~~~~~~~
    ucs2any.c:159:8: warning: implicit conversion loses integer precision: 'int' to
     'char' [-Wconversion]
                    *t = toupper(*t);
                       ~ ^~~~~~~~~~~
    ucs2any.c:305:27: warning: implicit conversion loses integer precision: 'int' t
    o 'char' [-Wconversion]
                    (*buffer)[position++] = c;
                                          ~ ^
    ucs2any.c:465:21: warning: comparison of integers of different signs: 'size_t'
    (aka 'unsigned long') and 'int' [-Wsign-compare]
            if (strlen(string) <= l) return NULL;
                ~~~~~~~~~~~~~~ ^  ~
    ucs2any.c:466:31: warning: implicit conversion changes signedness: 'int' to 'si
    ze_t' (aka 'unsigned long') [-Wsign-conversion]
            if (strncmp(string, pattern, l) != 0) return NULL;
                ~~~~~~~                  ^
    ucs2any.c:463:10: warning: implicit conversion loses integer precision: 'size_t
    ' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
            int l = strlen(pattern);
                ~   ^~~~~~~~~~~~~~~
    ucs2any.c:730:14: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                    target = strtol(p+2, &endp, 16);
                                           ~ ^~~~~~~~~~~~~~~~~~~~~~
    ucs2any.c:738:11: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                    ucs = strtol(p+2, &endp, 16);
                                        ~ ^~~~~~~~~~~~~~~~~~~~~~
    ucs2any.c:843:19: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                            bbx.cwidth = w;
                                                       ~ ^
    ucs2any.c:844:20: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                            bbx.cheight = h;
                                                        ~ ^
    ucs2any.c:845:18: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                            bbx.cxoff = x;
                                                      ~ ^
    ucs2any.c:846:18: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                            bbx.cyoff = y;
                                                      ~ ^
    ucs2any.c:850:7: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                                    w, h, x, y, &bbx);
                                                    ^
    ucs2any.c:850:10: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                                    w, h, x, y, &bbx);
                                                       ^
    ucs2any.c:850:13: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                                    w, h, x, y, &bbx);
                                                          ^
    ucs2any.c:850:16: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
                                                    w, h, x, y, &bbx);
                                                             ^
    
    Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>



More information about the xorg-commit mailing list