[master] b124cf4 Rename struct VSM_fantom to vsm_fantom to be consistent with the naming pattern which has evolved.

Poul-Henning Kamp phk at FreeBSD.org
Mon Jun 19 07:57:06 CEST 2017


commit b124cf41d8a99c52c9b556ff475fa220c2917f7c
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Mon Jun 19 05:55:39 2017 +0000

    Rename struct VSM_fantom to vsm_fantom to be consistent with the
    naming pattern which has evolved.

diff --git a/bin/varnishadm/varnishadm.c b/bin/varnishadm/varnishadm.c
index f9177d0..b983c52 100644
--- a/bin/varnishadm/varnishadm.c
+++ b/bin/varnishadm/varnishadm.c
@@ -396,7 +396,7 @@ n_arg_sock(const char *n_arg)
 	struct vsm *vsm;
 	char *p;
 	int sock;
-	struct VSM_fantom vt;
+	struct vsm_fantom vt;
 
 	vsm = VSM_New();
 	AN(vsm);
diff --git a/bin/varnishstat/varnishstat_curses.c b/bin/varnishstat/varnishstat_curses.c
index ab32eca..791ce69 100644
--- a/bin/varnishstat/varnishstat_curses.c
+++ b/bin/varnishstat/varnishstat_curses.c
@@ -313,7 +313,7 @@ build_pt_list_cb(void *priv, const struct VSC_point *vpt)
 }
 
 static void
-build_pt_list(struct vsm *vd, struct VSM_fantom *fantom)
+build_pt_list(struct vsm *vd, struct vsm_fantom *fantom)
 {
 	struct pt_priv pt_priv;
 	int i;
@@ -1050,7 +1050,7 @@ do_curses(struct vsm *vd, double delay)
 	long t;
 	int ch;
 	double now;
-	struct VSM_fantom f_iter = VSM_FANTOM_NULL;
+	struct vsm_fantom f_iter = VSM_FANTOM_NULL;
 
 	interval = delay;
 
diff --git a/bin/varnishtest/vtc_varnish.c b/bin/varnishtest/vtc_varnish.c
index 96046c2..1488ce6 100644
--- a/bin/varnishtest/vtc_varnish.c
+++ b/bin/varnishtest/vtc_varnish.c
@@ -77,7 +77,7 @@ struct varnish {
 	char			*proto;
 
 	struct vsm		*vd;		/* vsc use */
-	struct VSM_fantom	mgt_arg_i;
+	struct vsm_fantom	mgt_arg_i;
 
 	unsigned		vsl_tag_count[256];
 
diff --git a/include/vapi/vsc.h b/include/vapi/vsc.h
index 01ea236..022ccfc 100644
--- a/include/vapi/vsc.h
+++ b/include/vapi/vsc.h
@@ -38,7 +38,7 @@
 #include "vapi/vsc_int.h"
 
 struct vsm;
-struct VSM_fantom;
+struct vsm_fantom;
 
 /*---------------------------------------------------------------------
  * VSC level access functions
@@ -80,13 +80,13 @@ void VSC_Destroy_Point(struct VSC_point **);
 
 typedef int VSC_iter_f(void *priv, const struct VSC_point *const pt);
 
-int VSC_Iter(struct vsm *vd, struct VSM_fantom *fantom, VSC_iter_f *func,
+int VSC_Iter(struct vsm *vd, struct vsm_fantom *fantom, VSC_iter_f *func,
     void *priv);
 	/*
 	 * Iterate over all statistics counters, calling "func" for
 	 * each counter not suppressed by any "-f" arguments.
 	 *
-	 * fantom points to a struct VSM_fantom. If non-NULL, it can be
+	 * fantom points to a struct vsm_fantom. If non-NULL, it can be
 	 * used with VSM_StillValid to check the validity of the points
 	 * returned.
 	 *
diff --git a/include/vapi/vsm.h b/include/vapi/vsm.h
index 4055b0a..a463e9a 100644
--- a/include/vapi/vsm.h
+++ b/include/vapi/vsm.h
@@ -43,7 +43,7 @@ struct vsm;
  * This structure is used to reference a VSM chunk
  */
 
-struct VSM_fantom {
+struct vsm_fantom {
 	struct VSM_chunk	*chunk;
 	void			*b;		/* first byte of payload */
 	void			*e;		/* first byte past payload */
@@ -142,19 +142,19 @@ void VSM_Close(struct vsm *vd);
 	 */
 
 
-void VSM__iter0(const struct vsm *vd, struct VSM_fantom *vf);
-int VSM__itern(const struct vsm *vd, struct VSM_fantom *vf);
+void VSM__iter0(const struct vsm *vd, struct vsm_fantom *vf);
+int VSM__itern(const struct vsm *vd, struct vsm_fantom *vf);
 
 #define VSM_FOREACH(vf, vd) \
     for (VSM__iter0((vd), (vf)); VSM__itern((vd), (vf));)
 	/*
 	 * Iterate over all chunks in shared memory
-	 * vf = "struct VSM_fantom *"
+	 * vf = "struct vsm_fantom *"
 	 * vd = "struct vsm *"
 	 */
 
-int VSM_Map(struct vsm *vd, struct VSM_fantom *vf);
-int VSM_Unmap(struct vsm *vd, struct VSM_fantom *vf);
+int VSM_Map(struct vsm *vd, struct vsm_fantom *vf);
+int VSM_Unmap(struct vsm *vd, struct vsm_fantom *vf);
 
 struct vsm_valid {
 	const char *name;
@@ -165,9 +165,9 @@ extern const struct vsm_valid VSM_valid[];
 extern const struct vsm_valid VSM_similar[];
 
 const struct vsm_valid *VSM_StillValid(const struct vsm *vd,
-    struct VSM_fantom *vf);
+    struct vsm_fantom *vf);
 	/*
-	 * Check the validity of a previously looked up VSM_fantom.
+	 * Check the validity of a previously looked up vsm_fantom.
 	 *
 	 * VSM_invalid means that the SHM chunk this fantom points to does
 	 * not exist in the log file any longer. Using the fantom's
@@ -196,7 +196,7 @@ const struct vsm_valid *VSM_StillValid(const struct vsm *vd,
 	 *   VSM_similar: a fantom with same dimensions exist in same position.
 	 */
 
-int VSM_Get(const struct vsm *vd, struct VSM_fantom *vf,
+int VSM_Get(const struct vsm *vd, struct vsm_fantom *vf,
     const char *class, const char *ident);
 	/*
 	 * Find a chunk, produce fantom for it.
diff --git a/lib/libvarnishapi/vsc.c b/lib/libvarnishapi/vsc.c
index 59f034b..c4245b7 100644
--- a/lib/libvarnishapi/vsc.c
+++ b/lib/libvarnishapi/vsc.c
@@ -228,7 +228,7 @@ vsc_filter(struct vsm *vd, const char *nm)
  */
 
 static int
-vsc_iter_elem(struct vsm *vd, const struct VSM_fantom *fantom,
+vsc_iter_elem(struct vsm *vd, const struct vsm_fantom *fantom,
     const struct vjsn_val *vv, struct vsb *vsb, VSC_iter_f *func, void *priv)
 {
 	struct VSC_point	point;
@@ -304,7 +304,7 @@ vsc_iter_elem(struct vsm *vd, const struct VSM_fantom *fantom,
 }
 
 static int
-vsc_iter_fantom(struct vsm *vd, const struct VSM_fantom *fantom,
+vsc_iter_fantom(struct vsm *vd, const struct vsm_fantom *fantom,
     struct vsb *vsb, VSC_iter_f *func, void *priv)
 {
 	int i = 0;
@@ -336,10 +336,10 @@ vsc_iter_fantom(struct vsm *vd, const struct VSM_fantom *fantom,
  */
 
 int
-VSC_Iter(struct vsm *vd, struct VSM_fantom *fantom, VSC_iter_f *func,
+VSC_Iter(struct vsm *vd, struct vsm_fantom *fantom, VSC_iter_f *func,
     void *priv)
 {
-	struct VSM_fantom	ifantom;
+	struct vsm_fantom	ifantom;
 	uint64_t u;
 	int i = 0;
 	struct vsb *vsb;
diff --git a/lib/libvarnishapi/vsl_cursor.c b/lib/libvarnishapi/vsl_cursor.c
index b393fe8..c161abb 100644
--- a/lib/libvarnishapi/vsl_cursor.c
+++ b/lib/libvarnishapi/vsl_cursor.c
@@ -64,7 +64,7 @@ struct vslc_vsm {
 	unsigned			options;
 
 	struct vsm			*vsm;
-	struct VSM_fantom		vf;
+	struct vsm_fantom		vf;
 
 	const struct VSL_head		*head;
 	const uint32_t			*end;
@@ -241,7 +241,7 @@ struct VSL_cursor *
 VSL_CursorVSM(struct VSL_data *vsl, struct vsm *vsm, unsigned options)
 {
 	struct vslc_vsm *c;
-	struct VSM_fantom vf;
+	struct vsm_fantom vf;
 	struct VSL_head *head;
 	int i;
 
diff --git a/lib/libvarnishapi/vsm.c b/lib/libvarnishapi/vsm.c
index 8efba40..8af47fd 100644
--- a/lib/libvarnishapi/vsm.c
+++ b/lib/libvarnishapi/vsm.c
@@ -205,7 +205,7 @@ VSM_n_Arg(struct vsm *vd, const char *arg)
 const char *
 VSM_Name(const struct vsm *vd)
 {
-	struct VSM_fantom vt;
+	struct vsm_fantom vt;
 
 	CHECK_OBJ_NOTNULL(vd, VSM_MAGIC);
 	if (VSM_Get(vd, &vt, "Arg", "-i"))
@@ -386,7 +386,7 @@ VSM_Abandoned(struct vsm *vd)
 /*--------------------------------------------------------------------*/
 
 void
-VSM__iter0(const struct vsm *vd, struct VSM_fantom *vf)
+VSM__iter0(const struct vsm *vd, struct vsm_fantom *vf)
 {
 
 	CHECK_OBJ_NOTNULL(vd, VSM_MAGIC);
@@ -396,7 +396,7 @@ VSM__iter0(const struct vsm *vd, struct VSM_fantom *vf)
 }
 
 int
-VSM__itern(const struct vsm *vd, struct VSM_fantom *vf)
+VSM__itern(const struct vsm *vd, struct vsm_fantom *vf)
 {
 	struct VSM_chunk *c = NULL;
 
@@ -448,7 +448,7 @@ VSM__itern(const struct vsm *vd, struct VSM_fantom *vf)
 /*--------------------------------------------------------------------*/
 
 int
-VSM_Map(struct vsm *vd, struct VSM_fantom *vf)
+VSM_Map(struct vsm *vd, struct vsm_fantom *vf)
 {
 
 	CHECK_OBJ_NOTNULL(vd, VSM_MAGIC);
@@ -460,7 +460,7 @@ VSM_Map(struct vsm *vd, struct VSM_fantom *vf)
 /*--------------------------------------------------------------------*/
 
 int
-VSM_Unmap(struct vsm *vd, struct VSM_fantom *vf)
+VSM_Unmap(struct vsm *vd, struct vsm_fantom *vf)
 {
 
 	CHECK_OBJ_NOTNULL(vd, VSM_MAGIC);
@@ -472,9 +472,9 @@ VSM_Unmap(struct vsm *vd, struct VSM_fantom *vf)
 /*--------------------------------------------------------------------*/
 
 const struct vsm_valid *
-VSM_StillValid(const struct vsm *vd, struct VSM_fantom *vf)
+VSM_StillValid(const struct vsm *vd, struct vsm_fantom *vf)
 {
-	struct VSM_fantom f2;
+	struct vsm_fantom f2;
 
 	CHECK_OBJ_NOTNULL(vd, VSM_MAGIC);
 	AN(vf);
@@ -502,7 +502,7 @@ VSM_StillValid(const struct vsm *vd, struct VSM_fantom *vf)
 }
 
 int
-VSM_Get(const struct vsm *vd, struct VSM_fantom *vf,
+VSM_Get(const struct vsm *vd, struct vsm_fantom *vf,
     const char *class, const char *ident)
 {
 



More information about the varnish-commit mailing list