Working otu what is happening in a network dependent app

Peter Riocreux par+wine_devel at silistix.com
Mon Mar 15 04:51:05 CST 2004


Mike McCormack <mike at codeweavers.com> writes:

> Peter Riocreux wrote:
> >  Is there a noddy Wine app that will just print out all the
> >  environment it sees to I can be *absolutely* sure that my app is
> >  seeing it?
> 
> run "wine wcmd", then type "set" at the prompt.

Bingo, thanks. It should indeed be seeing the correct string.

> > Is there a specific set of debug messages I can turn on to see (a)
> > the app looking up the environment and (b) trying to open a
> > network connection.
> 
> (a) isn't so easy... maybe use +relay and sort thru what that gives

Sorry for the many lines here (I ended upjust using +all), but I
*think* it is revealing. The following is from a grep for 'LM_' and
all the returned lines seem to be connected to my env variable (the
initial numbers on the lines are line numbers in the log file, added
for me by grep).

1905:0009:trace:nls:WideCharToMultiByte cp 0 L"LM_LICENSE_FILE=1717 at au.silistix.com" -> (null)
1967:0009:trace:nls:WideCharToMultiByte cp 0 L"LM_LICENSE_FILE=1717 at au.silistix.com" -> "LM_LICENSE_FILE=1717 at au.silistix.com"
22537:000b:trace:nls:WideCharToMultiByte cp 0 L"LM_LICENSE_FILE=1717 at au.silistix.com" -> (null)
22600:000b:trace:nls:WideCharToMultiByte cp 0 L"LM_LICENSE_FILE=1717 at au.silistix.com" -> "LM_LICENSE_FILE=1717 at au.silistix.com"
727368:000b:Call kernel32.MultiByteToWideChar(000004e4,00000009,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000a,00000000,00000000) ret=78014de6
727370:000b:Call kernel32.MultiByteToWideChar(000004e4,00000001,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000a,4088f028,0000000a) ret=78014e26
727372:000b:Call kernel32.CompareStringW(00000000,00000001,4088f03c L"MODEL_TECH\n",0000000a,4088f028 L"LM_LICENSEMODEL_TECH\n",0000000a) ret=78014e3e
736057:000b:Call kernel32.MultiByteToWideChar(000004e4,00000009,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000e,00000000,00000000) ret=78014de6
736059:000b:Call kernel32.MultiByteToWideChar(000004e4,00000001,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000e,4088f34c,0000000e) ret=78014e26
736061:000b:Call kernel32.CompareStringW(00000000,00000001,4088f368 L"MODEL_TECH_TCL\000e",0000000e,4088f34c L"LM_LICENSE_FILMODEL_TECH_TCL\000e",0000000e) ret=78014e3e
737553:000b:Call kernel32.MultiByteToWideChar(000004e4,00000009,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000b,00000000,00000000) ret=78014de6
737555:000b:Call kernel32.MultiByteToWideChar(000004e4,00000001,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000b,4088f350,0000000b) ret=78014e26
737557:000b:Call kernel32.CompareStringW(00000000,00000001,4088f368 L"TCL_LIBRARY\7801\000b",0000000b,4088f350 L"LM_LICENSE_\7801TCL_LIBRARY\7801\000b",0000000b) ret=78014e3e
739071:000b:Call kernel32.MultiByteToWideChar(000004e4,00000009,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000a,00000000,00000000) ret=78014de6
739073:000b:Call kernel32.MultiByteToWideChar(000004e4,00000001,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000a,4088f340,0000000a) ret=78014e26
739075:000b:Call kernel32.CompareStringW(00000000,00000001,4088f354 L"TK_LIBRARY\n",0000000a,4088f340 L"LM_LICENSETK_LIBRARY\n",0000000a) ret=78014e3e
740611:000b:Call kernel32.MultiByteToWideChar(000004e4,00000009,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000b,00000000,00000000) ret=78014de6
740613:000b:Call kernel32.MultiByteToWideChar(000004e4,00000001,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000b,4088f364,0000000b) ret=78014e26
740615:000b:Call kernel32.CompareStringW(00000000,00000001,4088f37c L"TIX_LIBRARY\7801\000b",0000000b,4088f364 L"LM_LICENSE_\7801TIX_LIBRARY\7801\000b",0000000b) ret=78014e3e
742173:000b:Call kernel32.MultiByteToWideChar(000004e4,00000009,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000c,00000000,00000000) ret=78014de6
742175:000b:Call kernel32.MultiByteToWideChar(000004e4,00000001,411110b0 "LM_LICENSE_FILE=1717 at au.silistix.com",0000000c,4088f350,0000000c) ret=78014e26
742177:000b:Call kernel32.CompareStringW(00000000,00000001,4088f368 L"VSIM_LIBRARY\000c",0000000c,4088f350 L"LM_LICENSE_FVSIM_LIBRARY\000c",0000000c) ret=78014e3e
764678:000d:trace:nls:WideCharToMultiByte cp 0 L"LM_LICENSE_FILE=1717 at au.silistix.com" -> (null)
764748:000d:trace:nls:WideCharToMultiByte cp 0 L"LM_LICENSE_FILE=1717 at au.silistix.com" -> "LM_LICENSE_FILE=1717 at au.silistix.com"
1469989:000d:Call kernel32.MultiByteToWideChar(000004e4,00000009,418b15c0 "LM_LICENSE_FILE=1717 at au.silistix.com",00000007,00000000,00000000) ret=00422400
1469991:000d:Call kernel32.MultiByteToWideChar(000004e4,00000001,418b15c0 "LM_LICENSE_FILE=1717 at au.silistix.com",00000007,4078fd94,00000007) ret=00422450
1469993:000d:Call kernel32.CompareStringW(00000000,00000001,4078fda4 L"DISPLAYB\0007",00000007,4078fd94 L"LM_LICEBDISPLAYB\0007",00000007) ret=00422468


If you look at the CompareStringW() calls, there seems to be something
screwy going on. 

Looking at line 727372, the first argument is "MODEL_TECH\n" whose
length is 11 characters, and it is being compared to
"LM_LICENSEMODEL_TECH\n" which looks suspiciously like it is
"LM_LICENSE_FILE" truncated at the 11th character and then having
"MODEL_TECH" appended.  The same algorithm works for lines 736061,
737557, 739075, 740615 and 742177 modulo some non-printing
characters. Line 1469993 seems to break this though.

As I don't know what it is (a) intending and (b) supposed to be doing,
I cannot tell if this is just weird shit or possibly a Wine bug

> (b) maybe a +winsock trace will give you that

I think it is not even getting as far as knowing where to open a
socket so it doesn't try, but I shall keep that in mind for later on.

Regards,

Peter



More information about the wine-devel mailing list