Hello there,

I just got the GNU C compiler to say

In function 'int snprintf(char*, size_t, const char*, ...)',
    inlined from 'void saveViewerParameters(const char*, const char*)' at 
/home/dcb/rpmbuild/BUILD/tigervnc-1.2.80-20130314svn5065/vncviewer/parameters.cxx:527:33:
/usr/include/bits/stdio2.h:65:44: warning: call to int 
__builtin___snprintf_chk(char*, long unsigned int, int, long unsigned int, 
const char*, ...) will always overflow destination buffer [enabled by default]
        __bos (__s), __fmt, __va_arg_pack ());

Source code is

    snprintf(write_error, sizeof(filepath), "Failed to write configuration 
file, "
         "can't open %s", filepath);

I think you might be better off with

    snprintf(write_error, sizeof(write_error), "Failed to write configuration 
file, "
         "can't open %s", filepath);

Regards

David Binderman                                           
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Tigervnc-users mailing list
Tigervnc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tigervnc-users

Reply via email to