Steve Hay wrote: >Jan Dubois wrote: > > >>The other issue you are seeing is that CoInitialize() needs to be called >>in each *thread* that wants to make COM calls. To do this properly, the >>module needs to provide a CLONE method if you are using Perl threads in >>5.8.x. >> >> >> >That's not an issue for me with mp1 because it's single-threaded on >Win32. I'll have to bear it in mind when moving to mp2, though, 'cos >that's multi-threaded on Win32. > Actually, it *is* an issue for me :(
mp1 only uses Perl in a single-threaded way on Win32, but the Apache.exe process itself has (by default) 50 threads which take turns to serve requests. So I find (with your fixed version of Win32::Shortcut) that several consecutive requests all work OK, but then sometime later a subsequent request gets served by a different thread and it breaks because the CoInit wasn't done there. Adding a CLONE method to Win32::Shortcut won't help this either because it's Apache threads causing the problem, not Perl threads. So it's back to my nasty %INC hacking now. Using mod_perl handlers is the only other suggestion so far, but it's not so easy in the software concerned for which I have to maintain CGI compatibility. - Steve ------------------------------------------------ Radan Computational Ltd. The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only. If you have received this message in error or there are any problems, please notify the sender immediately. The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden. Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd. The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email. -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html