[GRASS-dev] [grass-code I][298] v.digit does not start from gis.m

Glynn Clements glynn at gclements.plus.com
Thu Feb 22 15:38:26 EST 2007


Maciej Sieczka wrote:

> Maris has submitted a patch with a hack/fix for this issue. Please see
> http://wald.intevation.org/tracker/?func=detail&atid=204&aid=298&group_id=21.
> It works for me, but it's hackish. Better ideas?

 	spawn d.mon start=$xmon

Rather than using "spawn", you could try "exec", but you need to
redirect the standard descriptors, otherwise exec won't return. E.g. 
(untested):

	global devnull
	exec d.mon start=$xmon >$devnull 2>$devnull

Although the d.mon process terminates once the monitor is accepting
connections, the monitor will inherit the stdout/stderr pipes which
Tcl's exec command creates, and exec won't return until these are
closed (it returns the entire output from the command as its result).

OTOH, I've been re-writing v.digit not to require a monitor, so
hopefully this issue should soon be moot.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-dev mailing list