On 21/11/08 15:14, Ben Schmidt wrote:
>>>> spell.c:7958: warning: ignoring return value of 'fwrite', declared with
>>>> attribute warn_unused_result
>> All the "new" warnings I see, with no exception, are for not using the
>> result of a function which returns a result of type warn_unused_result.
>>
>> My first impression was that:
>> - these warnings were probably related to the new define
>> FORTIFY_SOURCE=1, which is set at the very end of the configure run.
>> - type warn_unused_result rather than char, int or whatever might have
>> been put in there by Bram to tell me that there will be a spurious warning.
>
> Not by Bram; he didn't write the C library that contains fwrite. But
> turning on FORTIFY_SOURCE made this annotation in the C library
> effective to produce warnings.
>
> Ben.

Not only fwrite. Here is the full list I get (in Huge gvim with Gnome2):

fwrite  used by: diff.c, spell.c
chdir   used by: diff.c, ex_docmd.c, window.c
fchown  used by: ex_cmds.c, fileio.c
dup     used by: fileio.c, main.c, os_unix.c, ui.c
fgets   used by: fileio.c
mblen   used by: mbyte.c
write   used by: os_unix.c, netbeans.c
read    used by: gui.c
strtol  used by: netbeans.c

Well, yes, I guess they weren't defined by Bram.

I had also missed the following two, which aren't about ignored results 
of functions; but maybe they aren't new either:
gui_gtk_x11.c:3420: warning: not enough variable arguments to fit a sentinel
if_perl.xs:463: warning: null argument where non-null required (argument 3)


Best regards,
Tony.
-- 
Next Friday will not be your lucky day.  As a matter of fact, you don't
have a lucky day this year.

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui