<?xml version="1.0" ?>
<kc>

<title>Wine Traffic</title>

<author contact="http://www.theshell.com/~vinn">Brian Vincent</author>
<issue num="292" date="30 Sep 2005 00:00:00 -0800" />
<intro> <p>This is the 292nd issue of the Wine Weekly News publication.
Its main goal is to search for the DBA hat. It also serves to inform you of what's going on around Wine. Wine is an open source implementation of the Windows API on top of X and Unix.  Think of it as a Windows compatibility layer.  Wine does not require Microsoft Windows, as it is a completely alternative implementation consisting of 100% Microsoft-free code, but it can optionally use native system DLLs if they are available.   You can find more info at <a href="http://www.winehq.org">www.winehq.org</a></p> </intro>
<stats posts="182" size="347" contrib="70" multiples="41" lastweek="28">

<person posts="9" size="16" who="wino at piments.com" />
<person posts="9" size="13" who="truiken at gmail.com (James Hawkins)" />
<person posts="7" size="12" who="oliver_stieber at yahoo.co.uk (Oliver Stieber)" />
<person posts="6" size="10" who="julliard at winehq.org (Alexandre Julliard)" />
<person posts="6" size="6" who="infyquest at gmail.com (Vijay Kiran Kamuju)" />
<person posts="6" size="4" who="dank at kegel.com" />
<person posts="5" size="32" who="wine-devel at kievinfo.com (Vitaliy Margolen)" />
<person posts="5" size="22" who="a_villacis at palosanto.com (=?ISO-8859-1?Q?Alex_Villac=ED=ADs_Lasso?=)" />
<person posts="5" size="16" who="kdekorte at yahoo.com (Kevin DeKorte)" />
<person posts="5" size="16" who="wine.dev at web.de (Detlef Riekenberg)" />
<person posts="5" size="7" who="mike at codeweavers.com (Mike McCormack)" />
<person posts="6" size="5" who="meissner at suse.de (Marcus Meissner)" />
<person posts="4" size="10" who="winehacker at gmail.com (Steven Edwards)" />
<person posts="4" size="10" who="rob at codeweavers.com (Robert Shearman)" />
<person posts="4" size="4" who="dmitry at baikal.ru (Dmitry Timoshkov)" />
<person posts="4" size="3" who="tony.lambregts at gmail.com (Tony Lambregts)" />
<person posts="4" size="3" who="dimi at lattica.com (Dimi Paun)" />
<person posts="4" size="2" who="ivanleo at gmail.com (Ivan Leo Puoti)" />
<person posts="3" size="8" who="jean at bornier.net (Jean Magnan de Bornier)" />
<person posts="3" size="5" who="molle.bestefich at gmail.com (Molle Bestefich)" />
<person posts="3" size="4" who="the3dfxdude at gmail.com (Jesse Allen)" />
<person posts="3" size="4" who="mark.hatsell at btinternet.com (Mark Hatsell)" />
<person posts="3" size="4" who="us at edmeades.me.uk (Ann &amp; Jason Edmeades)" />
<person posts="3" size="4" who="phil at newstar.rinet.ru (Phil Krylov)" />
<person posts="3" size="4" who="wanderbored at yahoo.com (Esko Woudenberg)" />
<person posts="3" size="3" who="aric at codeweavers.com (Aric Stewart)" />
<person posts="3" size="3" who="dclark at akamail.com (Duane Clark)" />
<person posts="3" size="2" who="ivg2 at cornell.edu (Ivan Gyurdiev)" />
<person posts="2" size="13" who="vberon at mecano.gme.usherb.ca (Vincent B&#233;ron)" />
<person posts="2" size="4" who="Jonathan at ErnstFamily.ch (Jonathan Ernst)" />
<person posts="2" size="4" who="most at museresearch.com (Michael Ost)" />
<person posts="2" size="3" who="josephhenryblack at yahoo.co.nz (josephblack)" />
<person posts="2" size="3" who="peter at piments.com" />
<person posts="2" size="3" who="petro at mail.ru (Peter Lemenkov)" />
<person posts="2" size="3" who="frank.richter at gmail.com (Frank Richter)" />
<person posts="2" size="3" who="fgouget at free.fr (Francois Gouget)" />
<person posts="2" size="2" who="wowbagger at sktc.net (David D. Hagood)" />
<person posts="2" size="2" who="xerox_xerox2000 at yahoo.co.uk (Robbert Xerox)" />
<person posts="2" size="2" who="kuba at mareimbrium.org (Kuba Ober)" />
<person posts="2" size="2" who="andi at rhlx01.fht-esslingen.de (Andreas Mohr)" />
<person posts="2" size="1" who="daniel.r.kegel at gmail.com (Dan Kegel)" />
<person posts="1" size="6" who="wijn at wanadoo.nl (Rein Klazes)" />
<person posts="1" size="6" who="titan.costa at wanadoo.fr (Christian Costa)" />
<person posts="1" size="3" who="blin at gmx.net (Kai Blin)" />
<person posts="1" size="3" who="hverbeet at gmail.com (H. Verbeet)" />
<person posts="1" size="3" who="ulrich.czekalla at utoronto.ca (Ulrich Czekalla)" />
<person posts="1" size="3" who="motub at planet.nl (Holly Bostick)" />
<person posts="1" size="2" who="denis at voxelsoft.com (Denis Lukianov)" />
<person posts="1" size="2" who="maxy at rivero.com.ar (Maximiliano Curia)" />
<person posts="1" size="1" who="brian.vincent at gmail.com (Brian Vincent)" />
<person posts="1" size="1" who="elfe-sysmail at elfe.mine.nu (Karsten Elfenbein)" />
<person posts="1" size="1" who="randy.galbraith at cox.net (Randy Galbraith)" />
<person posts="1" size="1" who="h.davies1 at physics.ox.ac.uk (Huw D M Davies)" />
<person posts="1" size="1" who="kevin at plop.org (Kevin Koltzau)" />
<person posts="1" size="1" who="jrliggett at cox.net (James Liggett)" />
<person posts="1" size="1" who="mstefani at redhat.com (Michael Stefaniuc)" />
<person posts="1" size="0" who="lionel.ulmer at free.fr (Lionel Ulmer)" />
<person posts="1" size="0" who="e666e at seznam.cz (Petr Kobalicek)" />
<person posts="1" size="0" who="j0zue at o2.pl" />
<person posts="1" size="0" who="mjung at iss.tu-darmstadt.de (Michael Jung)" />
<person posts="1" size="0" who="stefandoesinger at gmx.at (=?ISO-8859-1?Q?=22Stefan_D=F6singer=22?=)" />
<person posts="1" size="0" who="marcelotduarte at gmail.com (Marcelo Duarte)" />
<person posts="1" size="0" who="lav at etersoft.ru (Vitaly Lipatov)" />
<person posts="1" size="0" who="mh at codeweavers.com (Mike Hearn)" />
<person posts="1" size="0" who="ricardoazzolini at hotmail.com (Ricardo Azzolini)" />
<person posts="1" size="0" who="rayjones at gmx.net (Ray Jones)" />
<person posts="1" size="0" who="lnd at denhulster.nl" />
<person posts="1" size="0" who="bjrobilliard at hotmail.com (Bryce Robilliard)" />

</stats>
<section 
	title="Summer of Code Update: Single Sign-On"
	subject="Single sign-on SoC project summary"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/040340.html"
	posts="1"
>
<topic>Status Updates</topic>
<mention>Juan Lang</mention>
<mention>Andrew Bartlett</mention>
<mention>cvs</mention>

<p>Kai Blin wrote in to give a status update of his Summer of Code project
to implement authentication within Wine:</p>
<quote who="Kai Blin"><p>
Dimi asked me to give a little status about the single sign-on summer of
code project I was doing to the list, and I'm happy to oblige.
</p><p>
Applications running on win32 can use the Security Support Provider
Interface (SSPI) to handle authentication via a number of protocols,
like kerberos, NTLM, Negotiate and Schannel. My project was to implement
the NTLM and Negotiate protocols, using Andrew Bartlett's GENSEC
implementation from samba4.
</p><p>
Samba offers a command line tool to provide NTLM ( and, in samba 4,
Negotiate ) style authentication for other programs, so my task was to
get wine to use ntlm_auth.

</p><p><u>Things that got done:</u><ul>

<li> Base64 codec
  ntlm_auth was first designed as a helper for squid. Squid talks to
  it's helpers using base64, wine just had an encoder for it.</li>

<li> Code to run ntlm_auth
  ntlm_auth doesn't store all the state information needed for the
  protocol handshake, so some wrapping code was needed.</li>

<li> Code that implements the security support providers for NTLM and
  Negotiate.
  To make the sspi functions behave properly, the api functions have to
  do the right thing.</li></ul>

</p><p><u>Work still left to do:</u><ul>

<li> Getting the code into cvs:
  While most of the code was already submitted to the wine-patches list,
  a lot of it was still in need of improvements. I'm currently working
  on this.</li>

<li> Getting more of the stubs to actually do something
  While the code that exists so far can handle the basic NTLM and
  Negotiate authentication, a lot of functions defined in the API still
  are stubs.</li></ul>

</p><p><u>Conclusion:</u></p><p>

As soon as the code is in cvs, wine should be able to do basic NTLM and
Negotiate authentication, server and client side. Client side just
requires ntlm_auth, server side also requires samba to be set up
correctly, and when using samba 3, access to the winbindd named pipe for
the user running wine. 
</p><p>
Real use of this code seems limited, as most use cases also use the
schannel protocol, which isn't implmented yet. Juan Lang is working on
this, but needs to get more of crypt32 implemented for that.
</p><p>
I will continue to work on this, there's still a lot of providers to go.
</p><p>
I would like to use this summary to extend my thanks to Google and Chris
DiBona for getting the whole Summer of Code set up.
</p><p>
Also, I'd like to thank you guys, particularly Juan, for the help I have
recieved so far. It's really fun to work with the project, I hope to
keep doing so for a while.
</p></quote>

 

</section>
<section 
	title="Summer of Code Update: Theming"
	subject="Theming SoC outcome"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/040289.html"
	posts="1"
>
<topic>Status Updates</topic>

<p>Another Summer of Code project was to add theming to Wine.  Frank
Richter gave a status update of his project:</p>
<quote who="Frank Richter"><p>
As some of you may have noticed, I did a bunch of theming-related work
in Wine, which was done within a project in Google's Summer of Code.
</p><p>
This is a small overview over what I've done:
<ul>
<li> All "non-standard" controls(those that are provided by comctl32, e.g.
</li>
Tabs) are themed and seem to work quite well so far.
<li> All standard controls except Buttons and Scrollbars are themed, though
not always perfect.
</li>
<li> Due the fact that uxtheme was actually used, a number of fixes and
improvements have been made.
</li></ul></p><p>

However, there are still things left open:
<ul>
<li> Bugs. Notably, the dreaded A->W WM_GETTEXTLENGTH issue breaking all
Delphi apps. Working on it though.
</li>
<li> A number of smaller and not so small visual glitches.
</li>
<li> Speed. Seems with alpha blending things are not exactly blazing along.
</li></ul></p><p>

At least for some of the issues I still have some ideas floating around,
so I guess I'll stick around a bit longer and try to get them fixed.
</p></quote>

</section>
<section 
	title="Red Hat/Fedora RPMs"
	subject="RH8 spec for 20050830"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/040377.html"
	posts="2"
>
<topic>Build Process</topic>
<p>Have you downloaded a Wine RPM for Red Hat or Fedora lately?  Hopefully
not.  Vincent B&#233;ron has been pretty busy and hasn't been able to
build any for a few months.  As a result, we've got some stale RPM's
on SourceForge.  Michael Ost seems to be interested in stepping up and
building a recent version:</p>
<quote who="Michael Ost"><p>
Can someone who understands wine build issues review this RPM spec file
for me, please?
</p><p>
The RPMs for Redhat 8 are getting pretty long in the tooth on the Wine
downloads page... dating back to May 24. I wanted to build a source RPM
to work with, so I modified the 20050524 spec file for 20050830.
</p><p>
It seems that there are changes in fonts and documentation. I removed
some lines that were keeping rpmbuild from working. But I feel like I am
tampering with issues beyond my grasp. Do the attached changes to the
spec file look ok (temporarily marked with "todo")? Any gotchas?
Anything missing?</p></quote>

<p>  Apparently Vincent has spent some time on it apparently:</p>
<quote who="Vincent Beron"><p>


<a href="http://www.winehq.com/pipermail/wine-devel/2005-September/040387.html">Attached</a>
 is the spec file I'm using for 20050830 on RH8 (not finished
building on all other distributions yet).</p><p>
--sysconfdir is not needed anymore by configure (harmless if present).
dlls/wineps had a installable file not installed by default (fixed since
then). See the diff for the rest of it, but your changes pretty much
covered it.
</p><p>
The fonts part is because not everyone has fontforge installed, so I
prefer to provide already built fonts. Not sure what was your problem
with the fonts.
</p></quote>
</section>
<section 
	title="Build Changes"
	subject="build errors"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/040381.html"
	posts="8"
>
<topic>Build Process</topic>
<mention>cvs</mention>

<p>Alexandre has been making some change to Wine's build system over the
past few weeks.  It's pretty far over my head and there's things like
outputting the delayed import table using assembly.  If that means 
nothing to you, don't worry.  It doesn't mean much to me either.  For the
most part this process has been completely seamless. However,
if you've run into problems building Wine recently it could be because 
of that.   Phil Krylov reported a problem with a lot of errors that 
looked like:</p>
<quote who="Phil Krylov"><p>
<ul><code>
__wine_spec_stress_dll_fini': /home/phil/build/wine/dlls/kernel/stress.spec.c:297:
undefined reference to __wine_call_from_16_long'</code></ul></p></quote>

<p>Marcelo Duarte reported the quick fix:</p>
<quote who="Marcelo Duarte"><p>
 To fix the problem for me, instead of clean, I'd do the folowing command
 in wine tree:
<ul><code>rm */*/*.spec.*</code></ul></p></quote>

<p>Marcus Meissner gave another solution using <tt>make clean</tt>:
</p><quote who="Marcus Meissner"><p>
After "cvs update" it no longer knew how to clean the tree.
<ul><code>
make clean<br />
cvs up<br />
./configure ...<br />
make depend<br />
make</code></ul></p><p>

is the right sequence, and not
<ul><code>cvs up<br />
./configure ...<br />
make clean<br />
make depend<br />
make</code></ul></p></quote>

<p>Oliver Stieber also noticed something else as a result of recent changes,
<quote who="Oliver Stieber">

I can no longer use .so's from older builds of wine with the current tree 
(which means I have to merge all my local changes, and merge any regression 
tests). </quote></p>

</section>
<section 
	title="Compile Problems from Wine-20050830"
	subject="Problem Resolve"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/040420.html"
	posts="5"
>
<topic>Fixes</topic>
<mention>WineHQ</mention>

<p>Someone ran into a problem compiling last month's CVS drop of Wine.
They explained the workaround:</p>
<quote who="Anonymous">
<p>I had a problem with Wine20050830 compilation.
<ul><code>
Error: error parse before "BerElement";</code></ul></p><p>
in lines: 289, 290, 322, 323 in "wine/dlls/wldap32/winldap_private.h" file.
</p><p>
In file winldap.h I found declaration of BerElement type. This header is not
included in winldap_private.h.
I put declaration of BerElement type to winldap_private.h and it resolved
the problem.
</p><p>
I tried add line: #include "winldap.h" to winldap.h too, but it makes double
declaration errors.
</p></quote>

<p>Molle Bestefich pointed out they should RTFM, or rather,
search the mailing list archives and dig through Bugzilla first before
posting on wine-devel.  In this case the problem was obscure enough
that posting to wine-devel was probably ok.  However, Molle did have a good 
idea that showstopper
items like that should be posted as news items on WineHQ.  At this point
it's a little late to include warnings for the August drop when September's
is likely close.  I replied back along those lines:</p>
<quote who="Brian Vincent"><p><ol>
<li>  Adding the Bugzilla entry as a news item is a good idea.  However,
we're possibly close to a September drop, so at this point it's
probably easiest to just wait for that.  I'm very open to adding news
items to the front page, so definitely feel free to drop me an email
when you think of things like that.  How about WWN coverage instead?</li>

<li>  CVS drops are just that - drops.  They haven't been compiled on a
bizillion systems or tested with real-world applications to ensure
things aren't massively broken.  Furthermore, no work was done to
stabilize the release other than normal bug fixes.  Instead, it
represents a point in time where Alexandre ran the regression tests,
things worked for him, and a tarball was made.  There was discussion
of that process changing after a beta release is made.</li>

<li>  Binary packages are highly recommended unless you prefer to muck
around occasionally with source code.  That probably doesn't apply to
you since you're reading wine-devel, but for 99% of the people in the
world they should use the binaries.  In theory we'll catch things at
that point.</li></ol></p></quote>


</section>
<section 
	title="Lotus Notes Breakage and Fix"
	subject="Wine CVS as of 9/25/2005 Kills Notes"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/.html"
	posts="11"
>
<topic></topic>
<mention>Oliver Stieber</mention>
<mention>Microsoft</mention>

<p>Adding functionality to Wine can actually break things more than it
fixes things sometimes.  That's especially true when a new DLL gets
added that consists mostly of "stubbed" functions that don't do anything
other than return a value like TRUE.  However, sometimes just getting
a base DLL stubbed out can be a lot of work.  It's been proven that
implementing stubs is a good way to encourage others to actually turn
the stubs into real functions.  That seems to be the case for usp10.dll,
the Uniscribe Script Processor.</p>

<p>Kevin DeKorte ran into a problem with Lotus Notes that included these
errors:</p>
<quote who="Kevin DeKorte"><p>
I updated CVS yesterday and then tried to run notes 6.51 and got this
backtrace. It works fine with 20050726

<ul><code>
$ wine ./nlnotes<br />
fixme:uniscribe:ScriptGetProperties 0x61be3aa8,0x61be3a7c<br />
fixme:uniscribe:ScriptRecordDigitSubstitution 1024,0x61be3a70<br />
wine: Call from 0x4154ba5c to unimplemented function<br />
usp10.dll.ScriptCacheGetHeight, aborting</code></ul></p></quote>

<p>Troy Rollo asked if it worked when Wine's builtin usp10.dll.so was
deleted from /usr/local/lib/wine.  Kevin reported that it did.  Alternatively, 
Oliver Stieber suggested just disabling the DLL in the DLL overrides.

</p><p>Troy blamed it on Wine's stub implementation
and described the correct fix:</p>
<quote who="Troy Rollo"><p>

OK, then a correct fix would involve implementing (or at least providing an
implementation that "appears" to return valid data) the entry point (and any
others used by Notes) rather than just providing a stub.
</p><p>
Unfortunately the documentation for the Uniscribe functions in MSDN is
atrocious even by Microsoft standards. At a guess Notes has called
ScriptGetFontProperties, which should populate the script variable.
</p><p>
Try the 
<a href="http://mail.google.com/mail/?view=att&amp;disp=attd&amp;attid=0.1&amp;th=106955b06dd806e2">following</a>
 (untested, may not even compile) as a starting point (You
will need to fill out the ScriptFreeCache entry in the spec file).
</p></quote>


</section>
<section 
	title="Finding Stack Corruption"
	subject="Help debugging a problem!"
	archive="http://www.winehq.com/hypermail/wine-devel/2005-September/040426.html"
	posts="8"
>
<topic>Debugging</topic>
<mention>Jason</mention>
<mention>Rein Klaze</mention>

<p>Trying to track down bugs can be daunting in any project, let
alone one the size of Wine.  Jason Edmeades described a strange 
one this week and asked for help:</p>
<quote who="Jason Edmeades"><p>

I've got a weird issue and was wondering if anyone could advise on how to
resolve. (Comes from a 16bit windows app, but is a more general debugging
issue).
</p><p>
The problem is ...
<ol>
<li> If I run the application, it just hangs - no overly helpful information
at all.</li>
<li> If I add WINEDEBUG +relay trace, it runs ok :-)  (Workaround...!)</li>
<li> If I add anything else on WINEDEBUG other than relay, it fails</li>
<li> Running under winedbg didn't help at all - I could code to stop it before
the hang but it wouldn't step through to the failure</li>
<li> Attaching to the hung process shows code in 16 bit user app, and winedbg
didn't overly help there either</li></ol>
</p><p>
So - I've (painstakingly) got to the point of failure with the add of debug
tracepoints and comparing the relay with the debug statements.
</p><p>
Now the odd bit!
</p><p>
If you look at dlls\user\wnd16.c, routine RegisterClass16 the final line is:
<ul><code>
    return RegisterClassEx16( &amp;wcex );</code></ul>
</p><p>
If I change this to
<ul><code>
    fred = RegisterClassEx16( &amp;wcex );<br />
    TRACE("Here... %d\n", fred);<br />
    return fred;
</code></ul></p><p>
it all works.....!
</p><p>
How can I debug this further? I was thinking about trying to dump the
registers before and after the trace statement, but I really can't think of
what could be causing the problem!</p></quote>

<p>James Hawkins thought it smelled like stack corruption:</p>
<quote who="James Hawkins"><p>


This sounds like the stack is getting trashed.  That is usually the
case when randomly added functions make it not crash.  You want to
look for places where local variables (on the stack of course) are
being overwritten.  A good example of this is copying a larger string
into a smaller local char array.  When looking for a stack crasher, I
comment out huge sections of code until it doesn't crash anymore, and
then piece by piece uncomment the next function.  For example,
<ul><code>
void foo()<br />
{<br />
#if 0
<ul><code>    a();<br />
    b();<br />
    c();</code></ul>
#endif<br />
}</code></ul></p><p>

doesn't crash, but
<ul><code>
void foo()<br />
{
<ul><code>    a();</code></ul>
#if 0
<ul><code>    b();<br />
    c();</code></ul>
#endif<br />
}</code></ul>

does crash, then your culprit is in a().  Then you recurse into a()
and repeat the process all over again till you find the stack crasher.
</p></quote>

<p>After more investigation, it appeared more likely the issue was
stack corruption.  Rein Klazes suggested:</p>
<quote who="Rein Klazes"><p>

This winedbg stack trace (info stack) is equivalent to the examine
command:
<ul><code>
x /24x $esp</code></ul></p><p>

(24 words == 0x60 bytes). Change the repeat count from 24 to what you
want. If there is a stack corruption, this way you can find out where
and then you can add a watch point on it.</p></quote>

</section></kc>
