]> granicus.if.org Git - postgresql/commitdiff
Fix missed usage of DLNewElem()
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 4 May 2009 02:46:36 +0000 (02:46 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 4 May 2009 02:46:36 +0000 (02:46 +0000)
src/backend/postmaster/postmaster.c

index 7cf6293bdce8b66f17dd0388d0044e15228081c8..7a20fadcd8ae4e87f89d84a78c1861d8aca0e23c 100644 (file)
@@ -37,7 +37,7 @@
  *
  *
  * IDENTIFICATION
- *       $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.579 2009/05/04 02:24:17 alvherre Exp $
+ *       $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.580 2009/05/04 02:46:36 tgl Exp $
  *
  * NOTES
  *
@@ -143,7 +143,7 @@ typedef struct bkend
        long            cancel_key;             /* cancel key for cancels for this backend */
        bool            is_autovacuum;  /* is it an autovacuum process? */
        bool            dead_end;               /* is it going to send an error and quit? */
-       Dlelem          elem;                   /* self pointer into BackendList */
+       Dlelem          elem;                   /* list link in BackendList */
 } Backend;
 
 static Dllist *BackendList;
@@ -4288,7 +4288,8 @@ StartAutovacuumWorker(void)
                                bn->cancel_key = MyCancelKey;
                                bn->is_autovacuum = true;
                                bn->dead_end = false;
-                               DLAddHead(BackendList, DLNewElem(bn));
+                               DLInitElem(&bn->elem, bn);
+                               DLAddHead(BackendList, &bn->elem);
 #ifdef EXEC_BACKEND
                                ShmemBackendArrayAdd(bn);
 #endif