Re: FVWM: large PipeReads

From: Dan Espen <dane_at_mk.telcordia.com>
Date: Thu, 18 Apr 2002 14:14:48 -0400

fvwm_at_fvwm.org writes:
> Ahh, you are putting the whole script _IN_ the config file?
>
> I think what Dominik meant was the return value needs to stay under 1022, may
> be I'm wrong, can someone clarify?

The limit is on the size of the command, not the result.

(The result can produce multiple lines, each one is a command.
So in the result, no line can exceed the limit.)

> The way I do it it to keep a script dir in my path and call them like this:
>
> PipeRead "addExecutableOnMenu BrowserPopup opera galeon konqueror mozilla net
> scape cnetscape"

Thats one way...

> So if I have a script over 1024 it will fail even if it's sitting in an exter
> nal file?

No.

Oops, looks like someone top posted:

>
> <snip>
> > I would vote in favor of an increase.

You might get your increase, but I don't really favor it.
It just uses up some memory for an extreme case that can be avoided
pretty easily.

Heres FvwmForm-Form dealing with the same limit:

# Caution, this command is getting too long, if you add something,
# you might have some truncation occur:
*FvwmForm-Form: Command !(/bin/echo \
 "# This file last created by FvwmForm-Form on: `/bin/date`."; /bin/echo \
 '*FvwmFormDefault: Font $(Font)' ; /bin/echo \
 '*FvwmFormDefault: InputFont $(InputFont)' ; /bin/echo \
 '*FvwmFormDefault: ButtonFont $(ButtonFont)'; /bin/echo \
 '*FvwmFormDefault: TimeoutFont $(TimeoutFont)'; /bin/echo \
 '*FvwmFormDefault: Fore $(Fore)' ; /bin/echo \
 '*FvwmFormDefault: Back $(Back)' ; /bin/echo \
 '*FvwmFormDefault: Colorset $(Colorset)' ; /bin/echo \
 '*FvwmFormDefault: ItemFore $(ItemFore)' ; /bin/echo \
 '*FvwmFormDefault: ItemBack $(ItemBack)' ; /bin/echo \
 '*FvwmFormDefault: ItemColorset $(ItemColorset)' ; /bin/echo \
 '*FvwmFormDefault: ButtonPointer $(ButtonPointer)' ; /bin/echo \
 '*FvwmFormDefault: ButtonInPointer $(ButtonInPointer)' ; /bin/echo \
 '*FvwmFormDefault: InputPointer $(InputPointer)' ; /bin/echo \
 '*FvwmFormDefault: ActivateOnPress $(ActivateOnPress)'\
) > ${FVWM_USERDIR}/.FvwmForm
# This would have surely hit a limit so its appended with >>:
*FvwmForm-Form: Command !(\
 /bin/echo '*FvwmFormDefault: ButtonPointerFore $(ButtonPointerFore)';\
 /bin/echo '*FvwmFormDefault: ButtonPointerBack $(ButtonPointerBack)';\
 /bin/echo '*FvwmFormDefault: ButtonInPointerFore $(ButtonInPointerFore)';\
 /bin/echo '*FvwmFormDefault: ButtonInPointerBack $(ButtonInPointerBack)';\
 /bin/echo '*FvwmFormDefault: InputPointerFore $(InputPointerFore)';\
 /bin/echo '*FvwmFormDefault: InputPointerBack $(InputPointerBack)';\
) >> ${FVWM_USERDIR}/.FvwmForm

-- 
Dan Espen                           E-mail: dane_at_mk.telcordia.com
444 Hoes Lane  Room RRC 1C-214      Phone: (732) 699-5570
Piscataway, NJ 08854
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Thu Apr 18 2002 - 13:19:24 BST

This archive was generated by hypermail 2.3.0 : Mon Aug 29 2016 - 19:37:53 BST