Skip to content

Instantly share code, notes, and snippets.

Created December 24, 2012 01:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/4366980 to your computer and use it in GitHub Desktop.
Save anonymous/4366980 to your computer and use it in GitHub Desktop.
albumart_convert.patch
diff -r -u src/rompr/uploadcover.php /srv/http/rompr/uploadcover.php
--- src/rompr/uploadcover.php 2012-11-18 19:55:32.000000000 +0100
+++ /srv/http/rompr/uploadcover.php 2012-12-24 01:37:25.423157952 +0100
@@ -26,15 +26,7 @@
unlink($small_file);
}
-// Test to see if convert is on the path and adjust if not - this makes
-// it work on MacOSX when everything's installed from MacPorts
$convert_path = "convert";
-$a = 1;
-$r = system($convert_path." > /dev/null", &$a);
-
-if ($a == 127) {
- $convert_path = "/opt/local/bin/convert";
-}
$r = system( $convert_path.' "'.$uploadfile.'" "'.$main_file.'"');
$r = system( $convert_path.' -resize 32x32 "'.$uploadfile.'" "'.$small_file.'"');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment