]> git.sur5r.net Git - bacula/bacula/commitdiff
Revert "Program currval retrieval somewhat more robust."
authorKern Sibbald <kern@sibbald.com>
Sat, 10 Apr 2010 10:14:33 +0000 (12:14 +0200)
committerKern Sibbald <kern@sibbald.com>
Sat, 10 Apr 2010 10:14:33 +0000 (12:14 +0200)
This reverts commit 2d02e4b0c13e2f26b138ebb411f6f5e253c91d4d.

bacula/src/cats/ingres.c

index b8a85ee5d5c8f94cfc3ff17308ed092db09c30d2..af3428b774d827baf4fb583d92f3ee46805d898c 100755 (executable)
@@ -647,7 +647,6 @@ static int my_ingres_currval(B_DB *mdb, const char *table_name)
 
    char sequence[64];
    char query[256];
-   char *currval;
    INGresult *result;
    int id = 0;
 
@@ -667,10 +666,7 @@ static int my_ingres_currval(B_DB *mdb, const char *table_name)
 
    Dmsg0(500, "exec done");
 
-   currval = INGgetvalue(result, 0, 0);
-   if (currval) {
-      id = atoi(currval);
-   }
+   id = atoi(INGgetvalue(result, 0, 0));
 
 bail_out:
    INGclear(result);