After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 739779 - Move a variable declaration to satisfy 'C' compilation
Move a variable declaration to satisfy 'C' compilation
Status: RESOLVED FIXED
Product: gdk-pixbuf
Classification: Platform
Component: general
git master
Other Windows
: Normal normal
: ---
Assigned To: gdk-pixbuf-maint
gdk-pixbuf-maint
Depends on:
Blocks:
 
 
Reported: 2014-11-07 13:01 UTC by John E
Modified: 2014-11-24 10:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Move a var declaration to the top of its ('C') function (928 bytes, patch)
2014-11-07 13:04 UTC, John E
committed Details | Review

Description John E 2014-11-07 13:01:02 UTC
In function 'gdk_pixbuf__tiff_image_save_to_callback()' (gdk-pixbuf/io-tiff.c) the variable 'codec' was previously declared inside a loop. That loop has now gone which means that (in order to satisfy some 'C' compilers) 'codec' must now get declared at the top of the function (along with all the other declarations). I've attached a patch which modifies that declaration.
Comment 1 John E 2014-11-07 13:04:48 UTC
Created attachment 290159 [details] [review]
Move a var declaration to the top of its ('C') function

I thought I'd already sent this attachment but I couldn't find it on checking the bug report!
Comment 2 Ignacio Casal Quinteiro (nacho) 2014-11-07 14:32:39 UTC
Review of attachment 290159 [details] [review]:

Looks good to me.
Comment 3 Fan, Chun-wei 2014-11-11 05:56:34 UTC
Review of attachment 290159 [details] [review]:

Hello John,

I have committed your diff to master as 1b8b69, but I have formatted it in 'git format-patch' format with a commit message (so it would be great if you can use 'git format-patch' to generate your diff/patch likewise).  Hope you don't mind that your name only appeared in the message body though, but thanks for this report, as I didn't pay enough attention to make sure GDK-Pixbuf builds under Visual Studio lately. :)

I will close this bug shortly.

With blessings, thank you!
Comment 4 John E 2014-11-24 10:20:05 UTC
I can confirm that 'git master' is building again with MSVC (although bug #739778 still needs to be resolved). Thanks.