Warnings: Difference between revisions

From vice-emu
Jump to navigation Jump to search
(Remove fixed warnings)
(Mark warning as fixed)
Line 86: Line 86:
                                                       ^~~~
                                                       ^~~~
12 warnings generated.
12 warnings generated.
===== This was fixed in r35671 =====
zfile.c:490:17: warning: logical not is only applied to the left hand side of this comparison [-Wlogical-not-parentheses]
zfile.c:490:17: warning: logical not is only applied to the left hand side of this comparison [-Wlogical-not-parentheses]
                 !strcasecmp(tmp + l - len, search) != 0) {
                 !strcasecmp(tmp + l - len, search) != 0) {
Line 98: Line 100:
                 (                                )                                                                                                                                                   
                 (                                )                                                                                                                                                   
1 warning generated.
1 warning generated.
===== End =====
</pre>
</pre>

Revision as of 17:58, 20 October 2018

GCC

clang

  • gpz (x86, Linux/Gentoo, 64bit, clang 5.0.1, GTK3) (3.2 tarball)
CC=clang CXX=clang LD=clang ./configure --enable-native-tools --enable-arch=native --prefix=/usr/games/ --enable-parsid --with-midas --with-resid --with-xaw3d --with-arts --with-x --enable-native-gtk3ui --enable-ethernet --with-pulse --with-sdlsound --enable-fullscreen --enable-cpuhistory --enable-static-ffmpeg

note: here compiling using clang breaks in either ffmpeg or resid

Making all in gfxoutputdrv
ffmpegdrv.c:126:36: warning: missing field 'next_pts' initializer [-Wmissing-field-initializers]
static OutputStream audio_st = { 0 };
                                   ^
ffmpegdrv.c:139:36: warning: missing field 'next_pts' initializer [-Wmissing-field-initializers]
static OutputStream video_st = { 0 };
                                   ^
ffmpegdrv.c:512:24: warning: missing field 'pts' initializer [-Wmissing-field-initializers]
    AVPacket pkt = { 0 };
                       ^
ffmpegdrv.c:981:28: warning: missing field 'pts' initializer [-Wmissing-field-initializers]
        AVPacket pkt = { 0 };
                           ^

Making all in base
keysetdialog.c:98:44: warning: suggest braces around initialization of subobject [-Wmissing-braces]
static GtkWidget *keyset_buttons[3][3] = { NULL };
                                           ^~~~
                                           {   }                                                                                                                                                     
/usr/lib64/llvm/5/bin/../../../../lib/clang/5.0.1/include/stddef.h:105:16: note: expanded from macro 'NULL'
#  define NULL ((void*)0)
               ^~~~~~~~~~
1 warning generated.
videopalettewidget.c:90:9: warning: unused variable 'index' [-Wunused-variable]
    int index = gtk_combo_box_get_active(combo);
        ^
1 warning generated.
ui.c:427:24: warning: unused variable 'tmp' [-Wunused-variable]
                gchar *tmp = g_filename_from_uri(files[i], NULL, NULL);
                       ^
1 warning generated.
uinetplay_new.c:88:9: warning: unused variable 'state' [-Wunused-variable]
    int state = gtk_switch_get_active(widget);
        ^

Making all in ffmpeg
In file included from info.c:34:
./infocontrib.h:293:8: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Andr<E9> Fachat <fachat@physik.tu-chemnitz.de>\n"
       ^~~~
./infocontrib.h:343:12: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Paul Dub<E9> \n"
           ^~~~
./infocontrib.h:444:8: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Istv<E1>n F<E1>bi<E1>n\n"
       ^~~~   ~~~~  ~~~~
./infocontrib.h:532:11: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Frank K<F6>nig <frank_koenig@t-online.de>\n"
          ^~~~
./infocontrib.h:571:11: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Marko M<E4>kel<E4> <msmakela@gmail.com>\n"
          ^~~~   ~~~~
./infocontrib.h:622:10: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Lasse <D6><F6>rni <loorni@mail.student.oulu.fi>\n"
         ^~~~~~~~
./infocontrib.h:655:14: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Pablo Rold<E1>n <pdroldan@yahoo.com>\n"
             ^~~~
./infocontrib.h:799:19: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
"  Peternel, Per H<E5>kan Sundell and David Horrocks for writing\n"
                  ^~~~
./infocontrib.h:841:25: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
    { "1996-2001", "Andr<E9> Fachat", "Andr<E9> Fachat <fachat@physik.tu-chemnitz.de>" },
                        ^~~~
./infocontrib.h:841:41: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
    { "1996-2001", "Andr<E9> Fachat", "Andr<E9> Fachat <fachat@physik.tu-chemnitz.de>" },
                                           ^~~~
./infocontrib.h:862:29: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
    { "2004-2017", "Paul Dub<E9>", "French", "Paul Dub<E9> " },
                            ^~~~
./infocontrib.h:862:52: warning: illegal character encoding in string literal [-Winvalid-source-encoding]
    { "2004-2017", "Paul Dub<E9>", "French", "Paul Dub<E9> " },
                                                      ^~~~
12 warnings generated.

===== This was fixed in r35671 =====
zfile.c:490:17: warning: logical not is only applied to the left hand side of this comparison [-Wlogical-not-parentheses]
                !strcasecmp(tmp + l - len, search) != 0) {
                ^                                  ~~
zfile.c:490:17: note: add parentheses after the '!' to evaluate the comparison first
                !strcasecmp(tmp + l - len, search) != 0) {
                ^
                 (                                     )                                                                                                                                             
zfile.c:490:17: note: add parentheses around left hand side expression to silence this warning
                !strcasecmp(tmp + l - len, search) != 0) {
                ^
                (                                 )                                                                                                                                                  
1 warning generated.
===== End =====