logo       

Re: DBD::Pg and $sth->{ParamValues}: msg#00008

Subject: Re: DBD::Pg and $sth->{ParamValues}
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
 
 
> What is the status of the this attribute? I would like to help
> implement the code (since I need it for my application).
 
Feel free to jump in. I'm pretty sure it is unsupported at the moment.
 
> But I'm a bit confused about what the status of prepared statements is
> in the code. I'm assuming the the dbd_st_execute() in dbdimp.c is the
> latest code used and that prescan_stmt.c isn't being used.
 
That is correct.
 
>               paramValues = calloc(imp_sth->numphs, sizeof(*paramValues));
>
> but it is never freed, isn't that a memory leak?
 
Yes, probably so. I don't like the use of calloc anyway, so if you
can find a way to use New() in a loop instead, I'd go that way. Feel
free to strip out the 'y' and 'z' ints as well, looks like those
are leftover debugging aids.
 
> this because in order to make the ParamValues attribute work, I'll
> need to make that array part of the statement handle - and I don't
> want to be keeping track of memory that is going to vanish out from
> underneath me.
 
Upon looking at the code again, I think everything you need is already
there, inside of imp_sth->seg->value. But getting rid of that calloc
would still be nice. :)
 
- --
Greg Sabino Mullane greg@xxxxxxxxxxxx
PGP Key: 0x14964AC8 200407021933
 
-----BEGIN PGP SIGNATURE-----
 
iD8DBQFA5fDvvJuQZxSWSsgRAqR7AKCbp97sb/Y1plTdJ0ucTOiNy2EXgACfQmzE
+X0SUFg+ImHdyUAobivwPoI=
=iCjA
-----END PGP SIGNATURE-----



---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
    (send "unregister YourEmailAddressHere" to majordomo@xxxxxxxxxxxxxx)



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
boot-loaders.gr...    php.pear.genera...    debugging.valgr...    kde.redhat.user...    text.xml.xsl.ge...    culture.languag...    hardware.microc...    java.servicemix...    redhat.release....    web.zope.plone....    user-groups.lin...    opendarwin.webk...    video.mjpeg.use...    sysutils.bcfg2....    encryption.gpg....    lx-office.devel...    xfree86.forum/2...    mail.mutt.devel...    acpi.devel/2003...    qnx.openqnx.dev...    network.irc.irs...    freebsd.devel.m...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe