Re: DBD::mysql patch for take_imp_data based threading
Patrick Galbraith <[email protected]>
| Newsgroups | gmane.comp.lang.perl.modules.dbi.sybase.devel |
|---|---|
| Message-ID | <[email protected]> |
Tim,
Thanks much- this seems to work. I decided to convert one of these tests
to using Test::More, and now I have this issue of:
ishvara:/home/patg/DBD-mysql-4.007 # PERL_DL_NONLAZY=1 /usr/bin/perl
"-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib',
'blib/arch')" t/70takeimp.t
t/70takeimp....ok 1/21# You named your test '1'. You shouldn't use
numbers for your test names.
# Very confusing.
t/70takeimp....ok
All tests successful.
Files=1, Tests=21, 1 wallclock secs ( 0.07 cusr + 0.01 csys = 0.08 CPU)
"You named your test 1" Strage error. I know it's probably something
simple and easy - has anyone a suggestion how I might get rid of this
error? I look at how I'm running this and everything looks good.
--Patrick
Tim Bunce wrote:
>On Thu, Apr 24, 2008 at 09:58:51PM -0400, Patrick Galbraith wrote:
>
>
>>Jeffrey,
>>
>>Thank you very much for this patch - I have tons of mail and originally
>>missed this. I've applied it and
>>found that it failed with an earlier version of DBI, but once I updated
>>DBI, it now passes along with Stas Beckman's patch he sent me for this a
>>year or two ago.
>>
>>Do you know what the specific version of this is that this feature was
>>added to DBI? I can put logic in the tests that ignore this test if the DBI
>>version is not supporting it.
>>
>>
>
>You could just do
>
> ... if $dbh->can('take_imp_data');
>
>Tim.
>
>
>
>>I'm going to include this with an upcoming 4.007 (this week) release.
>>
>>Thanks!
>>
>>Patrick
>>
>>
>>[email protected] wrote:
>>
>>
>>
>>>Following on the heels of the DBI and DBD::Oracle patches, I figured getting mysql
>>>to work would be the next best step. Unfortunately I kept getting a glibc free() error,
>>>similar to the one here:
>>>
>>>http://www.nntp.perl.org/group/perl.dbi.dev/2005/04/msg4039.html
>>>
>>>The problem is the imp_dbh contains a MYSQL structure, and part of this structure
>>>is pointers to other MYSQL structures - or, usually, back to the original structure.
>>>
>>>When you take the imp_data and put it into another SV, its address in memory changes,
>>>so anything pointing to this struct is going to break.
>>>
>>>The simplest thing I found was to change the MYSQL struct to a pointer. The other DBD
>>>drivers I've looked at all use a pointer or an opaque handle, so it should work. However,
>>>it feels like a pretty extensive patch just to support an experimental change. Try
>>>it out and let me know what you think.
>>>
>>>
>>>
>>>** ** ** PRIVILEGED AND CONFIDENTIAL ** ** **
>>>This email transmission contains privileged and confidential information intended only for the use of the individual or entity named above. Any unauthorized review, use, disclosure or distribution is prohibited and may be a violation of law. If you are not the intended recipient or a person responsible for delivering this message to an intended recipient, please delete the email and immediately notify the sender via the email return address or mailto:[email protected]. Thank you.
>>>
>>>- end -
>>>
>>>
>>>
>>>
>>--
>>Patrick Galbraith, Senior Programmer Grazr - Easy feed grazing and sharing
>>http://www.grazr.com
>>Satyam Eva Jayate - Truth Alone Triumphs
>>Mundaka Upanishad
>>
>>
>>
>>
--
Patrick Galbraith, Senior Programmer
Grazr - Easy feed grazing and sharing
http://www.grazr.com
Satyam Eva Jayate - Truth Alone Triumphs
Mundaka Upanishad