--- a2ps-4.13/src/select.c.shell 2004-07-29 16:43:08.178940204 +0100
+++ a2ps-4.13/src/select.c 2004-07-29 16:43:09.328722698 +0100
@@ -148,8 +148,10 @@
command = ALLOCA (char, (2
+ strlen (job->file_command)
+ ustrlen (filename)));
- sprintf (command, "%s %s", job->file_command, (const char *) filename);
- message (msg_tool, (stderr, "Reading pipe: `%s'\n", command));
+ setenv ("filename", (const char *) filename, 1);
+ sprintf (command, "%s \"${filename}\"", job->file_command);
+ message (msg_tool, (stderr, "Reading pipe: `%s' [filename=%s]\n", command,
+ (const char *) filename));
file_out = popen (command, "r");
/* Check for failure */