[Spacewalk-list] Installed Systems/Target Systems - 500 error
Jan Pazdziora
jpazdziora at redhat.com
Sun Oct 9 09:51:44 UTC 2011
On Tue, Sep 20, 2011 at 05:28:12PM +0200, Gerald wrote:
> Hi,
>
> with your GIT patch, I now get for both functions the same
> "Cannot bind unknown placeholder ':p1'" error.
>
> I've changed the code according to your advice:
> --
> --- /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm.orig 2011-09-20
> 17:11:35.000000000 +0200
> +++ /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm 2011-09-20
> 17:18:28.000000000 +0200
> @@ -557,7 +557,9 @@
> $self->bind_param_inout(":$k" => $v, 4096, $attr);
> }
> else {
> - $self->bind_param(":$k" => $v, $attr);
> + eval {$self->bind_param(":$k" => $v, $attr)};
> + if($@) { use Carp; Carp::confess("$k $v $attr") }
Can you turn this to Carp::cluck? This way we get the die at the
very first invocation which is probably not what we want -- we want
to see the original error with the unknown placeholder.
--
Jan Pazdziora
Principal Software Engineer, Satellite Engineering, Red Hat
More information about the Spacewalk-list
mailing list