Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2004:
[Freeciv-Dev] (PR#11671) Error in XP with limited user

[Freeciv-Dev] (PR#11671) Error in XP with limited user

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: paul@xxxxxxxxxxxxx
Subject: [Freeciv-Dev] (PR#11671) Error in XP with limited user
From: "James Canete" <use_less@xxxxxxxxxxx>
Date: Sat, 25 Dec 2004 19:59:57 -0800
Reply-to: bugs@xxxxxxxxxxx

<URL: >

I can't reproduce this bug, but I suspect that tmpfile() is failing in
utility/netintf.c, line 214.  Most likely a limited user doesn't have
write permissions to whereever the temp file wants to exist.

I also notice that this is only used in client/clinet.c, function

I'm not sure of a proper fix.  The problem is that with a sufficiently
limited user, she may not have any place where a temp file can be
written.  The first thing to pop into mind is to make the registry
parsing functions work with files in memory as well as those on disk,
then store the metaserver response into memory and parse it there, but
that's a bit of a tall order for a bug that only shows up on win32. :)

I suppose the easiest fix would simply be to bail out if tmpfile()
fails.  Here's a patch that does that. :) The error message is
potentially misleading, though.

-James Canete

Attachment: win32-fix-notmpfile.diff
Description: Binary data

[Prev in Thread] Current Thread [Next in Thread]