Hello, during my work for the gtk frontend of debian-installer I encounterd a bug in directfb.
When trying to find executable specific configuration, directfb
segfaults if there is no calling program. At least I believe that this
is the cause.
The segfault happend at the (*) starred line:
,----[DirectFB-0.9.15/src/misc/conf.c, Line 683]
| DFBResult dfb_config_init( int *argc, char **argv[] )
| {
| DFBResult ret;
| int i;
| char *home = getenv( "HOME" );
| char *prog = NULL;
|
| if (dfb_config)
| return DFB_OK;
|
| config_allocate();
|
| ret = dfb_config_read( "/etc/directfbrc" );
| if (ret && ret != DFB_IO)
| return ret;
|
| if (argc && argv) {
|* prog = strrchr( (*argv)[0], '/' );
|
| if (prog)
| prog++;
| else
| prog = (*argv)[0];
| }
`----
argc and argv were valid pointers, so the if clause was entered. But
*argc was 0x0 so (*argv)[0] was a nullpointer dereferenciation.
I hope that helps.
Sebastian Ley
--
PGP-Key: http://www.mmweg.rwth-aachen.de/~sebastian.ley/public.key
Fingerprint: A46A 753F AEDC 2C01 BE6E F6DB 97E0 3309 9FD6 E3E6
msg01256/pgp00000.pgp
Description: PGP signature
