]> granicus.if.org Git - php/commitdiff
MFH: handle unsupported datatypes and prevent segfault
authorAntony Dovgal <tony2001@php.net>
Thu, 28 Apr 2005 14:12:23 +0000 (14:12 +0000)
committerAntony Dovgal <tony2001@php.net>
Thu, 28 Apr 2005 14:12:23 +0000 (14:12 +0000)
ext/oci8/oci8.c

index 2cf27ff9090e72442aaeb86dfd056be2304744ad..4fdc6404243d135820cd24664f1066a7a709bb20 100644 (file)
@@ -3695,6 +3695,10 @@ break;
                        }
                        value_sz = sizeof(void*);
                        break;
+               default:
+                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown or unsupported datatype given: %u", ocitype);
+                       RETURN_FALSE;
+                       break;
        }
        
        if ((ocitype == SQLT_CHR) && (value_sz == -1)) {