Hi Jade,
Could you please try the attached patch?
regards,
Hiroshi Inoue
On 2014/10/15 14:38, Jade Koskela wrote:
> Here is the end of the log.
> I've done some debugging, when CC_send_query_append is called here, it
> correctly identifies that there was an error, and exits the function.
>
> res = CC_send_query_append(conn, self->stmt_with_params, qryi, qflag,
> SC_get_ancestor(self), appendq); (statement.c:2069)
>
> The result which is returned is not handled correctly (statement.c:2078)
>
> if (appendq)
> {
> QResultClass *qres, *nres;
>
> if ( res->rstatus == PORES_EMPTY_QUERY && !res->next)
> res = NULL;
>
> for (qres = res; qres;)
> {
> if (qres->command && strnicmp(qres->command, fetch_cmd, 5) == 0)
> {
> res = qres;
> break;
> }
> nres = qres->next;
> if (nres && QR_get_notice(qres) != NULL)
> {
> if (QR_command_successful(nres) &&
> QR_command_nonfatal(qres))
> {
> QR_set_rstatus(nres, PORES_NONFATAL_ERROR);
> }
> QR_add_notice(nres, QR_get_notice(qres));
> }
> qres->next = NULL;
> QR_Destructor(qres);
> qres = nres;
> }
> }
>
> There is only a single result, with result.next == NULL.
> This part of the code calls the destructor on the only result, but res
> is still left pointing at it. After that fun things happen.
> It gets a long way before it actually crashes in
> Exec_with_parameters_resolved.