Don't pass NULL to dlclose. Stops the simulator crashing if there's a problem loading a plugin or codec.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9003 a1c6a512-1295-4272-9138-f99709370657
diff --git a/docs/CREDITS b/docs/CREDITS
index 906e3d0..ccc174b 100644
--- a/docs/CREDITS
+++ b/docs/CREDITS
@@ -179,3 +179,4 @@
 Alun Thomas
 Nils Wallménius
 Naoaki Okazaki
+Will Dyson
diff --git a/uisimulator/common/io.c b/uisimulator/common/io.c
index 56cdb46..9115ef2 100644
--- a/uisimulator/common/io.c
+++ b/uisimulator/common/io.c
@@ -361,7 +361,6 @@
 #else
         DEBUGF("dlopen(%s): %s\n", path, dlerror());
 #endif
-        dlclose(*pd);
         return NULL;
     }
 
@@ -399,7 +398,6 @@
 #else
         DEBUGF("dlopen(%s): %s\n", path, dlerror());
 #endif
-        dlclose(*pd);
         return NULL;
     }