void vbe_free_bereq(struct bereq *bereq);
/* cache_ban.c */
+void AddBan(const char *);
void BAN_Init(void);
void cli_func_url_purge(struct cli *cli, char **av, void *priv);
void BAN_NewObj(struct object *o);
#include "shmlog.h"
#include "cli_priv.h"
#include "cache.h"
-#include "vrt.h"
struct ban {
TAILQ_ENTRY(ban) list;
static unsigned ban_next;
static struct ban *ban_start;
-static void
+void
AddBan(const char *regexp)
{
struct ban *b;
AddBan("a");
}
-
-void
-VRT_repurge(const char *regexp)
-{
- AddBan(regexp);
-}
strcat(q, p);
return (q);
}
+
+/*--------------------------------------------------------------------*/
+
+void
+VRT_purge(const char *regexp)
+{
+
+ AddBan(regexp);
+}
int VRT_re_test(struct vsb *, const char *, int sub);
const char *VRT_regsub(struct sess *sp, const char *, void *, const char *);
-void VRT_repurge(const char *);
+void VRT_purge(const char *);
void VRT_count(struct sess *, unsigned);
int VRT_rewrite(const char *, const char *);
/*--------------------------------------------------------------------*/
static void
-parse_repurge(struct tokenlist *tl)
+parse_purge(struct tokenlist *tl)
{
vcc_NextToken(tl);
- Fb(tl, 0, "VRT_repurge(");
+ Fb(tl, 0, "VRT_purge(");
Expect(tl, '(');
vcc_NextToken(tl);
{ "call", parse_call },
{ "set", parse_set },
{ "remove", parse_remove },
- { "purge", parse_repurge },
+ { "purge", parse_purge },
{ NULL, NULL }
};
vsb_cat(sb, "int VRT_re_test(struct vsb *, const char *, int sub);\n");
vsb_cat(sb, "const char *VRT_regsub(struct sess *sp, const char *, void *, const char *);\n");
vsb_cat(sb, "\n");
- vsb_cat(sb, "void VRT_repurge(const char *);\n");
+ vsb_cat(sb, "void VRT_purge(const char *);\n");
vsb_cat(sb, "\n");
vsb_cat(sb, "void VRT_count(struct sess *, unsigned);\n");
vsb_cat(sb, "int VRT_rewrite(const char *, const char *);\n");