]> granicus.if.org Git - postgresql/commitdiff
Silence warning in non-assert-enabled build
authorAlvaro Herrera <alvherre@alvh.no-ip.org>
Thu, 5 Mar 2015 15:11:26 +0000 (12:11 -0300)
committerAlvaro Herrera <alvherre@alvh.no-ip.org>
Thu, 5 Mar 2015 18:38:37 +0000 (15:38 -0300)
An OID return value was being used only for a (rather pointless) assert.
Silence by removing the variable and the assert.

Per note from Peter Geoghegan

src/backend/catalog/pg_conversion.c

index 7de738722bc82741623f89822e6e1a846ed4a131..56ab016cc9cf410e07e1f01ff33cb492f3af6c70 100644 (file)
@@ -50,7 +50,6 @@ ConversionCreate(const char *conname, Oid connamespace,
        bool            nulls[Natts_pg_conversion];
        Datum           values[Natts_pg_conversion];
        NameData        cname;
-       Oid                     oid;
        ObjectAddress myself,
                                referenced;
 
@@ -106,8 +105,7 @@ ConversionCreate(const char *conname, Oid connamespace,
        tup = heap_form_tuple(tupDesc, values, nulls);
 
        /* insert a new tuple */
-       oid = simple_heap_insert(rel, tup);
-       Assert(OidIsValid(oid));
+       simple_heap_insert(rel, tup);
 
        /* update the index if any */
        CatalogUpdateIndexes(rel, tup);