Bug #321: dlls/msvct/vf[w]printf functions
Jaco Greeff
jaco at puxedo.org
Mon Oct 28 02:04:49 CST 2002
Dmitry Timoshkov wrote:
> Doing a cursory look I don't see anything other (again, apart from L"something"
> and (WCHAR)L'%').
That (the WCHARL'%' switch/case) is the one case for which I don't have
an answer for. Originally I had the code looking as follows:
INT somefunc(LPCWSTR lpszStr)
{
while (*lpszStr) {
switch (*lpszStr) {
case '%': do_something(); break;
...
In other parts of the wine code (I need to find it again, but a grep on
the sources should turn it up), generally these types of things gets
written as (maybe I just looked in entirely the wrong place ;),
INT somefunc(LPCWSTR lpszStr)
{
while (*lpszStr) {
switch (*lpszStr) {
case (WCHAR)L'%': do_something(); break;
...
and consequently I've adapted my code to do the same. I'm not sure what
is the "correct" approach to take in this regard. So, yes, I'm quite
happy to rid ourselves of the L"something" in the test code and making
sure I use WideCharToMultiByte in the correct place, for the above case
I need some guidance.
What is the best way to handle these? If the (WCHAR)L'%' thing is not
the way to go, I'll be happy to make a patch for the other parts as
well. (Once I have an idea of the best way to handle this.)
Greetings,
Jaco
More information about the wine-devel
mailing list