On Sun, Oct 08, 2006 at 07:44:31PM +0200, Hernani Marques Madeira wrote: > I managed to write a patch for supertux to avoid this. It should also > help with the default fullscreen option, although there is certainly > more to fix before enabling this back. Could someone please commit the patches patch-ab to patch-ad as provided by Pierre, because I have no more write access; for me they work as expected. Thanks for committing and to Pierre for providing them! -- hernani
$NetBSD$ --- src/music_manager.cpp.orig 2005-06-21 23:16:07.000000000 +0200 +++ src/music_manager.cpp @@ -40,7 +40,10 @@ MusicManager::load_music(const std::stri return MusicRef(0); if(!exists_music(file)) - st_abort("Couldn't load musicfile ", file.c_str()); + { + st_warn("Couldn't load musicfile ", file.c_str()); + return MusicRef(0); + } std::map<std::string, MusicResource>::iterator i = musics.find(file); assert(i != musics.end()); @@ -119,7 +122,7 @@ MusicManager::halt_music() void MusicManager::enable_music(bool enable) { - if(!audio_device) + if(!audio_device || current_music == 0) return; if(enable == music_enabled)
$NetBSD$ --- src/setup.cpp.orig 2005-07-08 14:19:17.000000000 +0200 +++ src/setup.cpp @@ -889,6 +889,14 @@ void st_abort(const std::string& reason, abort(); } + +/* --- WARN! --- */ + +void st_warn(const std::string& reason, const std::string& details) +{ + fprintf(stderr, "\nWarning: %s\n%s\n\n", reason.c_str(), details.c_str()); +} + /* Set Icon (private) */ void seticon(void)
$NetBSD$ --- src/setup.h.orig 2005-06-21 23:16:07.000000000 +0200 +++ src/setup.h @@ -42,6 +42,7 @@ void st_joystick_setup(void); void st_shutdown(void); void st_menu(void); void st_abort(const std::string& reason, const std::string& details); +void st_warn(const std::string& reason, const std::string& details); void process_options_menu(void); /** Return true if the gameloop() was entered, false otherwise */
Attachment:
pgpJDNVFSLY_y.pgp
Description: PGP signature
------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________ pkgsrc-wip-discuss mailing list pkgsrc-wip-discuss%lists.sourceforge.net@localhost https://lists.sourceforge.net/lists/listinfo/pkgsrc-wip-discuss