Code

Committed patch 170667
authorjiho-sf <jiho-sf@users.sourceforge.net>
Thu, 21 Jun 2007 08:32:27 +0000 (08:32 +0000)
committerjiho-sf <jiho-sf@users.sourceforge.net>
Thu, 21 Jun 2007 08:32:27 +0000 (08:32 +0000)
"There is a small bashism in share/extenions/ps2pdf.sh. This will result in a problem when using "Save As..." with "PDF with Text and Images" selected on systems using /bin/dash as the default shell.
Even if this kind of PDF output does not exist anymore...

share/extensions/ps2pdf.sh

index 1b7c4cfa38e4c95d6851a7b56f84f884c73c6226..3e77ec30a006b6cb77fc918158533542ad2ec609 100755 (executable)
@@ -1,8 +1,8 @@
-#! /bin/sh
+#!/bin/sh
 
 params=`grep "^%%DocumentMedia:" "$1" | head -n 1 | awk '{  if (NF==7) { if ($2!="plain") print "-sPAPERSIZE=" $2; else print "-dDEVICEWIDTHPOINTS=" $3 " -dDEVICEHEIGHTPOINTS=" $4; } }'`
 
-if [ "x${params}x" == "xx" ]
+if [ "x${params}x" = "xx" ]
 then 
         params=`grep "^%%BoundingBox:" "$1" | head -n 1 | awk '{ print "-dDEVICEWIDTHPOINTS=" $4 " -dDEVICEHEIGHTPOINTS=" $5; }'`
 fi