SYSTEMROOT, SYSTEMDRIVE
egor duda
deo@logos-m.ru
Thu May 10 02:25:00 GMT 2001
Hi!
Thursday, 10 May, 2001 Christopher Faylor cgf@redhat.com wrote:
CF> The difference is the call to the "OS". It's optional in my case and
CF> mandatory in yours. I don't know if this makes a difference but I would
CF> bet that the scanning of the environment is not a quick process. That
CF> would be weighed against the potentially extra two elements to be sorted
CF> by qsort.
CF> Hmm. Actually, you stop checking for the extra variables after the
CF> build of winenv passes the place where they would be placed, too,
CF> so that is a difference.
yes, because both lists are sorted.
CF> I don't know. I think that the calls to GetEnvironmentVariable outweigh
CF> anything else, especially since most of the time they probably aren't
CF> needed.
CF> Comments?
you're right. always calling GetEnvironmentVariable is a waste of
time. i've changed my patch to
- avoid repeated scanning of forced env vars list.
- look into native environment only when needed.
- don't truncate forced vars values to MAX_PATH symbols.
Egor. mailto:deo@logos-m.ru ICQ 5165414 FidoNet 2:5020/496.19
force-systemroot-2.diff
force-systemroot-2.ChangeLog
-------------- next part --------------
2001-05-10 Egor Duda <deo@logos-m.ru>
* environ.cc (append_to_winenv): New function.
(winenv): Always add SYSTEMDRIVE and SYSYEMROOT to win32-style
environment.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: force-systemroot-2.diff
Type: text/x-diff
Size: 4360 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20010510/d38ccce3/attachment.bin>
More information about the Cygwin-patches
mailing list