Red Hat Bugzilla – Bug 162143
'offset' is used uninitialized in this function
Last modified: 2007-11-30 17:11:09 EST
Description of problem:
I just tried to compile package gtkhtml3-3.6.2-1 from Redhat
Fedora Core development tree with the gcc 4.0.0 compiler and
the compiler flag -Wall.
The compiler said
gtkhtml.c:3285: warning: 'offset' is used uninitialized in this function
The source code is
D_IM (printf ("IM gtk_html_im_retrieve_surrounding_cb\n");)
gtk_im_context_set_surrounding (context, get_surrounding_text
(html->engine, &offset), -1, offset);
I agree with the compiler. This code would benefit from rework, because
there is no defined ordering on the evaluation of function parameters.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
Thanks for this report. I'll try to get this fixed upstream.
I've sent a patch upstream for this
(this is now fixed in upstream CVS, and in the current rawhide gtkhtml3 tarball)