www.delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-developers-help AT cygwin DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-developers-subscribe AT cygwin DOT com> |
List-Archive: | <http://sources.redhat.com/ml/cygwin-developers/> |
List-Post: | <mailto:cygwin-developers AT cygwin DOT com> |
List-Help: | <mailto:cygwin-developers-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs> |
Sender: | cygwin-developers-owner AT cygwin DOT com |
Delivered-To: | mailing list cygwin-developers AT cygwin DOT com |
From: | "Gerald S. Williams" <gsw AT agere DOT com> |
To: | <cygwin-developers AT cygwin DOT com> |
Subject: | Re: True case-sensitive filenames |
Date: | Fri, 24 Jan 2003 13:01:19 -0500 |
Message-ID: | <GBEGLOMMCLDACBPKDIHFIEFADBAA.gsw@agere.com> |
MIME-Version: | 1.0 |
X-Priority: | 3 (Normal) |
X-MSMail-Priority: | Normal |
X-MimeOLE: | Produced By Microsoft MimeOLE V6.00.2800.1106 |
Importance: | Normal |
In-Reply-To: | <GBEGLOMMCLDACBPKDIHFGEDFDBAA.gsw@agere.com> |
> The next thing to try is attempting to set the current > working directory using NtSetInformationProcess(). I'm > currently way over my Cygwin-development allotment for > this week, though. I just couldn't let this one sit, so I stayed up late working on it. Sure enough, you can set the current directory in a case-sensitive fashion. I verified that GetCurrentDirectory() responds to the change (Cygwin's getcwd() currently doesn't, of course). You don't actually use NtSetInformationProcess()--you just need to get at the PEB somehow (you could use NtQueryInformationProcess(), but NtCurrentTeb()->Peb is faster). Peb->FastPebLockRoutine(Peb->FastPebLock) locks the structure, then you can directly change Peb->ProcessParameters->CurrentDirectoryHandle and Peb->ProcessParameters->CurrentDirectoryName. -Jerry
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |