Bug 545279

Summary: mozplugger configuration file errors out if acroread is absent
Product: [Fedora] Fedora Reporter: Michal Jaegermann <michal>
Component: mozpluggerAssignee: Than Ngo <than>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 12CC: than
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-09-29 12:05:30 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michal Jaegermann 2009-12-08 01:53:14 UTC
Description of problem:

/etc/mozpluggerrc is run through m4 and contains the following code:

# Trap only version 5 assume the rest work OK (6 onwards...)
ifelse(esyscmd([acroread -v | grep "^[^0-9]*5\..*$"]), [], [
  define(ACROREAD, [ACROREAD_FLAGS() : acroread ACROREAD_OPTS() "$file"])
],[
  define(ACROREAD, [ACROREAD_FLAGS5() : acroread ACROREAD_OPTS5() "$file"])
])

If acroread happens NOT to be present on an installation this results in the following error: "sh: acroread: command not found" and on occasions takes a long while to get there.

That really checks for an ancient version of acroread which nobody should use anymore if only for security reasons; so all the above could be really replaced by:

define(ACROREAD, [ACROREAD_FLAGS() : acroread ACROREAD_OPTS() "$file"])

Switching positions of evince and acroread in a PDF block of /etc/mozpluggerrc would make also less likely that somebody with an antique on hands will hit it when using mozplugger even if options are "wrong".

Version-Release number of selected component (if applicable):
mozplugger-1.12.1-7.fc12

How reproducible:
always without acroread in PATH

Comment 1 Michal Jaegermann 2009-12-09 18:13:34 UTC
If you are reluctant to cause difficulties even for those with a long obsolete version of acroread then instead of 'acroread -v' in esyscmd the following will work surely better regardless of what kind of a shell is in use:

   bash -c "type -p acroread >/dev/null && acroread -v"

Comment 2 Than Ngo 2010-09-29 12:05:30 UTC
it should be fixed in mozplugger-1.14.2-1.fc13 which will be available in f13-update-testing soon. Or you can download it from http://koji.fedoraproject.org/koji/buildinfo?buildID=189076