Set the node properly, per Tom.
authorAlvaro Herrera <alvherre@alvh.no-ip.org>
Fri, 23 Mar 2007 21:57:10 +0000 (21:57 +0000)
committerAlvaro Herrera <alvherre@alvh.no-ip.org>
Fri, 23 Mar 2007 21:57:10 +0000 (21:57 +0000)
src/backend/postmaster/autovacuum.c

index 183fe963ecad2466861dbdb8f29d424fe2fca2fa..15fe23d81494e0c9122f4df8301f80ff1cbfd36a 100644 (file)
@@ -1276,6 +1276,8 @@ autovacuum_do_vac_analyze(Oid relid, bool dovacuum, bool doanalyze,
        VacuumStmt      vacstmt;
        MemoryContext old_cxt;
 
+       MemSet(&vacstmt, 0, sizeof(vacstmt));
+
        /*
         * The list must survive transaction boundaries, so make sure we create it
         * in a long-lived context
@@ -1283,6 +1285,7 @@ autovacuum_do_vac_analyze(Oid relid, bool dovacuum, bool doanalyze,
        old_cxt = MemoryContextSwitchTo(AutovacMemCxt);
 
        /* Set up command parameters */
+       vacstmt.type = T_VacuumStmt;
        vacstmt.vacuum = dovacuum;
        vacstmt.full = false;
        vacstmt.analyze = doanalyze;