> I am seeing a bug with trying to get the contents of a field widget
> which happens to be empty - the pgGetString() call hangs indefinitely.
> This is using either 0.4.3, or the latest cvs snapshot. This test
> program will cause the problem:
> 
> #include <picogui.h>
> 
> int main(int argc, char **argv) {
>   pghandle wField;
> 
>   pgInit(argc,argv);
>   pgRegisterApp(PG_APP_NORMAL,"Greetings",0);
> 
>   wField = pgNewWidget(PG_WIDGET_FIELD,0,0);
>   pgSetWidget(PGDEFAULT,
>               PG_WP_SIDE,PG_S_ALL,
>               PG_WP_TEXT,pgNewString("H"),
>               0);
>   printf("%s\n",pgGetString(pgGetWidget(wField,PG_WP_TEXT)));
>   /*We never reach this line*/
>   
>   pgEventLoop();
>   return 0;
> }

Fixed.
By the way, your code doesn't reproduce the bug. You have to remove the H
or comment the full line to make it hang... :)
-philippe


-------------------------------------------------------
This sf.net email is sponsored by:
With Great Power, Comes Great Responsibility 
Learn to use your power at OSDN's High Performance Computing Channel
http://hpc.devchannel.org/
_______________________________________________
Pgui-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/pgui-devel

Reply via email to