- if(file_exists($convert = "/usr/local/bin/$prog") ||
- file_exists($convert = "/usr/bin/$prog") ||
- ($convert = `which convert` != '' && file_exists($convert))) {
- return $convert;
+ if(file_exists($path = "/usr/local/bin/$prog") ||
+ file_exists($path = "/usr/bin/$prog") ||
+ ($path = `which $prog` != '' && file_exists($path))) {
+ return $path;