--- kdeprint/filters/imagetops.orig Wed Nov 28 12:25:21 2001 +++ kdeprint/filters/imagetops Wed Nov 28 12:29:50 2001 @@ -27,11 +27,17 @@ # check the file mime type, and set the command correspondingly cmd= magic=`file -bi $FILE` -if [[ $magic != image/* ]] ; then - echo "Not an image" - exit 1; -fi -case ${magic/image\//} in + +case $magic in + image/*) + ;; + *) + echo "Not an image" + exit 1; + ;; +esac + +case ${magic##image\/} in jpeg) cmd="djpeg -pnm" ;;