Re: [Stlport-devel] Backport r3345 to 5.1?
Brought to you by:
complement
From: <fra...@fr...> - 2008-01-02 21:32:54
|
Path has been applied to 5.1 branch and comment added in trunk. About support for GetFileInformationByHandle, my PSDK doc says that it is also present under Windows 95 98. I wonder why online MSDN says that it is only available starting with W2k, maybe they simply consider Windows 95 and 98 as not supported anymore. I asked why the guy that made the Windows CE console patch change the call to GetFileType and never get answer, do you know if it should be prefered to GetFileInformationByHandle ? I think test should rather be: ((info.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) == 0) do you agree ? I think we will have a 5.1.5, there are already a number of bug fixes in 5.1 branch and don't think we will release 5.2 before at least a month. Bests Ulrich Eckhardt wrote: > Hi! > > I ported the part concerning the console window to 5.1. The diff from trunk > applies cleanly, but I also commented _why_ and _how_ the workaround works. > Is there any plan to release another 5.1 version where this could be included > or will I have to wait for 5.2? In any case, I'd suggest adding the comments > to the trunk, too, just because the workaround is rather non-obvious. > > > Also, in that revision was a change that implemented __is_regular_file() in > terms of GetFileInformationByHandle(). This function is supported since MS > Windows CE 1 (so no problem for CE) but only since w2k for the desktop > variants. > > Also, the check (in its final form in r3346) is pretty obfuscated: > > ((info.dwFileAttributes ^ FILE_ATTRIBUTE_DIRECTORY) != 0) > > is equivalent to this (replacing a!=b with !(a==b)): > > !((info.dwFileAttributes ^ FILE_ATTRIBUTE_DIRECTORY) == 0): > > which is equivalent to this (a^b==0 when a==b): > > !(info.dwFileAttributes == FILE_ATTRIBUTE_DIRECTORY) > > which then finally becomes this: > > info.dwFileAttributes != FILE_ATTRIBUTE_DIRECTORY > > which is much easier to read than the original but I wonder if this is really > what was intended. > > > cheers > > Uli > > |