Code

varnish plugin: fix build against pre varnish 5.2
authorMarc Fournier <marc.fournier@camptocamp.com>
Wed, 8 Nov 2017 20:55:04 +0000 (21:55 +0100)
committerMarc Fournier <marc.fournier@camptocamp.com>
Wed, 8 Nov 2017 21:15:38 +0000 (22:15 +0100)
Older Varnish versions don't know about VSM_Destroy()

src/varnish.c

index 67c5bfd126d0f7fdc9d657ccb23c727d7819fe6a..69daa980c1ab1995925c1cce949c09d04794b0fe 100644 (file)
@@ -1390,7 +1390,7 @@ static int varnish_read(user_data_t *ud) /* {{{ */
 #endif
 #if HAVE_VARNISH_V3 || HAVE_VARNISH_V4
   if (!ok) {
-    VSM_Destroy(&vd);
+    VSM_Delete(vd);
     ERROR("varnish plugin: Unable to open connection.");
     return -1;
   }
@@ -1403,7 +1403,7 @@ static int varnish_read(user_data_t *ud) /* {{{ */
 #endif
 #if HAVE_VARNISH_V3 || HAVE_VARNISH_V4
   if (!stats) {
-    VSM_Destroy(&vd);
+    VSM_Delete(vd);
     ERROR("varnish plugin: Unable to get statistics.");
     return -1;
   }