Subject: Fix fs->vol_name handling
This patch checks wether fs->vol_name exists and handles the case where it doesn't exist. That fixes the lockup that occurs when trying to run qemu-system-ppc -cdrom <iso> -boot d
Signed-off-by: Stefan Assmann sassmann@suse.de
Index: modules/filesystems.c =================================================================== --- modules/filesystems.c (revision 418) +++ modules/filesystems.c (working copy) @@ -145,8 +145,12 @@
if( !mi->volname ) mi->volname = malloc( VOLNAME_SIZE ); - - ret = mi->fs->vol_name( mi->fs, mi->volname, VOLNAME_SIZE ); + /* handle case where there is no vol_name function in fs */ + if( !mi->fs->vol_name ) { + mi->volname[0] = '\0'; + ret = mi->volname; + } else + ret = mi->fs->vol_name( mi->fs, mi->volname, VOLNAME_SIZE ); PUSH( (ucell)ret ); }
Stefan