Search
lxdream.org :: lxdream/src/config.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/config.c
changeset 608:4f588e52bce0
prev561:533f6b478071
next643:653b0a70f173
author nkeynes
date Sat Jan 26 02:45:27 2008 +0000 (13 years ago)
permissions -rw-r--r--
last change Bug #50: Implement mouse and keyboard
file annotate diff log raw
1.1 --- a/src/config.c Tue Jan 01 05:08:38 2008 +0000
1.2 +++ b/src/config.c Sat Jan 26 02:45:27 2008 +0000
1.3 @@ -312,12 +312,13 @@
1.4 fprintf( f, "Device %d = %s\n", i, dev->device_class->name );
1.5 else
1.6 fprintf( f, "Subdevice %d = %s\n", j, dev->device_class->name );
1.7 - entry = dev->get_config(dev);
1.8 - while( entry->key != NULL ) {
1.9 - if( entry->value != NULL ) {
1.10 - fprintf( f, "%*c%s = %s\n", j==0?4:8, ' ',entry->key, entry->value );
1.11 + if( dev->get_config != NULL && ((entry = dev->get_config(dev)) != NULL) ) {
1.12 + while( entry->key != NULL ) {
1.13 + if( entry->value != NULL ) {
1.14 + fprintf( f, "%*c%s = %s\n", j==0?4:8, ' ',entry->key, entry->value );
1.15 + }
1.16 + entry++;
1.17 }
1.18 - entry++;
1.19 }
1.20 }
1.21 }
.