[GRASS5] [bug #3518] (grass) G_tempfile() - possible problems in programs switching locations

Request Tracker grass-bugs at intevation.de
Sat Aug 13 08:01:15 EDT 2005

this bug's URL: http://intevation.de/rt/webrt?serial_num=3518

Subject: G_tempfile() - possible problems in programs switching locations

Platform: GNU/Linux/i386
grass obtained from: CVS
grass binary for platform: Compiled from Sources
GRASS Version: 61 cvs 13.08.05


This is a followup of a discussion on the (fixed) bug https://intevation.de/rt/webrt?serial_num=3362&display=History

Brad Douglas wrote:

>>> Yes, it's in G_asprintf(). Simply changing G_tempfile() back to
>>> tmpfile() on line 37 in asprintf.c fixes it. There may be other
>>> consequences so I suggest the maintainer makes the reversion himself in
>>> cvs.

Paul Kelly wrote:

>> Probably would need to think about systematically changing some other 
>> occurences of G_tempfile() as Glynn and Morten suggested.

Glynn Clements wrote:

> I agree.
> The alternative is to require any program which switches locations
> using G__switch_env() to ensure that G_tempfile() doesn't get called
> while the location is switched. Given that calls to G_tempfile() could
> be hidden deep down in the call graph, that requirement would be
> extremely hard to comply with.


-------------------------------------------- Managed by Request Tracker

More information about the grass-dev mailing list