]> granicus.if.org Git - postgresql/blobdiff - src/backend/commands/user.c
I really hope that I haven't missed anything in this one...
[postgresql] / src / backend / commands / user.c
index a5b1715be42d1541c05a2e30d2c17b99e16b38c0..08088eb4b7f43f8c6a3282e20ad6fe6723cc324b 100644 (file)
 
 #include <miscadmin.h>
 #include <catalog/catname.h>
+#ifdef MB
+#include <catalog/pg_database_mb.h>
+#else
 #include <catalog/pg_database.h>
+#endif
 #include <catalog/pg_shadow.h>
 #include <libpq/crypt.h>
 #include <access/heapam.h>
@@ -65,7 +69,7 @@ UpdatePgPwdFile(char *sql)
         * file to its final name.
         */
        sprintf(sql, "copy %s to '%s' using delimiters %s", ShadowRelationName, tempname, CRYPT_PWD_FILE_SEPCHAR);
-       pg_exec_query(sql, (char **) NULL, (Oid *) NULL, 0);
+       pg_exec_query(sql);
        rename(tempname, filename);
        free((void *) tempname);
 
@@ -196,7 +200,7 @@ DefineUser(CreateUserStmt *stmt)
        }
        strcat(sql_end, ")");
 
-       pg_exec_query(sql, (char **) NULL, (Oid *) NULL, 0);
+       pg_exec_query(sql);
 
        /*
         * Add the stuff here for groups.
@@ -328,7 +332,7 @@ AlterUser(AlterUserStmt *stmt)
        {
                sql_end += strlen(sql_end);
                sprintf(sql_end, " where usename = '%s'", stmt->user);
-               pg_exec_query(sql, (char **) NULL, (Oid *) NULL, 0);
+               pg_exec_query(sql);
        }
 
        /* do the pg_group stuff here */
@@ -450,7 +454,7 @@ RemoveUser(char *user)
                elog(NOTICE, "Dropping database %s", dbase[ndbase]);
                sprintf(sql, "drop database %s", dbase[ndbase]);
                free((void *) dbase[ndbase]);
-               pg_exec_query(sql, (char **) NULL, (Oid *) NULL, 0);
+               pg_exec_query(sql);
        }
        if (dbase)
                free((void *) dbase);
@@ -477,7 +481,7 @@ RemoveUser(char *user)
         * Remove the user from the pg_shadow table
         */
        sprintf(sql, "delete from %s where usename = '%s'", ShadowRelationName, user);
-       pg_exec_query(sql, (char **) NULL, (Oid *) NULL, 0);
+       pg_exec_query(sql);
 
        UpdatePgPwdFile(sql);