Red Hat Bugzilla – Bug 43829
obscure i18n bug with current a2ps (4.13b-14)
Last modified: 2007-04-18 12:33:36 EDT
The current rawhide a2ps package has the default medium set to "_glibc",
which is apparently some magic string to tell a2ps to ask glibc what paper
size to use by default.
The first problem is that this isn't documented anywhere in the a2ps
documentation, as far as I could tell.
The second problem is that the functionality in glibc depends on the LANG
variable being set properly, and LANG does not get set properly in shells
started for cron jobs, because /etc/bashrc only executes the stuff in
/etc/profile.d in interactive shells.
As a result of this, cron jobs which call a2ps (and I have one, which is
why I noticed this) use the wrong paper size.
I'm not sure the bug is in a2ps. In fact, the bug may be in the decision
not to set i18n variables properly in non-interactive shells. But it
manifests itself in a2ps, so I'm filing it under that component. If y'all
end up deciding that the problem is really with /etc/bashrc, you can move
the bug into the "component" category or something.
I think that the second problem is a symptom of the first; it should be
documented that LANG needs to be set correctly for automatic paper size to
work, and that it may not be in non-interactive shells.
Documentation added in a2ps-4.13b-18.