Skip an unneeded check. Simply call rmdir, and if it's empty it goes - if not, it stays.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18109 a1c6a512-1295-4272-9138-f99709370657
diff --git a/tools/buildzip.pl b/tools/buildzip.pl
index 9bd896b..973163d 100755
--- a/tools/buildzip.pl
+++ b/tools/buildzip.pl
@@ -284,12 +284,8 @@
 
         find(find_copyfile(qr/.*\.codec/, abs_path('.rockbox/codecs/')), 'apps/codecs');
 
-        my @call = `find .rockbox/codecs -type f 2>/dev/null`;
-        if(!$call[0]) {
-            # no codec was copied, remove directory again
-            rmdir(".rockbox/codecs");
-
-        }
+        # remove directory again if no codec was copied
+        rmdir(".rockbox/codecs");
     }
 
     find(find_copyfile(qr/\.(rock|ovl)/, abs_path('.rockbox/rocks/')), 'apps/plugins');