summaryrefslogtreecommitdiffstats
path: root/plugins/omoracle
diff options
context:
space:
mode:
authorLuis Fernando Munoz Mejias <Luis.Fernando.Munoz.Mejias@cern.ch>2009-11-12 14:40:30 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2009-11-12 14:40:30 +0100
commit4ed50bb87466ecaba05e6fc53892926997120c18 (patch)
treee5bc41992bd757bdb3683c0b58834fbddbb45648 /plugins/omoracle
parentd06b63272d9d5eb568201026bfd42be2be845b18 (diff)
downloadrsyslog-4ed50bb87466ecaba05e6fc53892926997120c18.tar.gz
rsyslog-4ed50bb87466ecaba05e6fc53892926997120c18.tar.xz
rsyslog-4ed50bb87466ecaba05e6fc53892926997120c18.zip
Improve the handling of OCI_SUCCESS_WITH_INFO.
Stop considering it as an error, and make it display the information from the Oracle server.
Diffstat (limited to 'plugins/omoracle')
-rw-r--r--plugins/omoracle/omoracle.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/plugins/omoracle/omoracle.c b/plugins/omoracle/omoracle.c
index ccb1593f..35478ef4 100644
--- a/plugins/omoracle/omoracle.c
+++ b/plugins/omoracle/omoracle.c
@@ -87,7 +87,8 @@ MODULE_TYPE_OUTPUT
DEF_OMOD_STATIC_DATA
DEFobjCurrIf(errmsg)
-/** */
+/** Structure defining a batch of items to be sent to the database in
+ * the same statement execution. */
struct oracle_batch
{
/* Batch size */
@@ -162,8 +163,10 @@ static int oci_errors(void* handle, ub4 htype, sword status)
return OCI_SUCCESS;
break;
case OCI_SUCCESS_WITH_INFO:
- errmsg.LogError(0, NO_ERRCODE, "OCI SUCCESS - With info\n");
- break;
+ OCIErrorGet(handle, 1, NULL, &errcode, buf, sizeof buf, htype);
+ errmsg.LogError(0, NO_ERRCODE, "OCI SUCCESS - With info: %s",
+ buf);
+ return OCI_SUCCESS;
case OCI_NEED_DATA:
errmsg.LogError(0, NO_ERRCODE, "OCI NEEDS MORE DATA\n");
break;