From 6bdf33145e81381bc36e553aee9b881e462cd39a Mon Sep 17 00:00:00 2001 From: phk Date: Mon, 7 Aug 2006 21:08:20 +0000 Subject: [PATCH] 64bit changes git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@754 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-cache/bin/varnishd/cache_acceptor.c | 4 ++-- varnish-cache/bin/varnishd/varnishd.c | 8 ++++---- varnish-cache/lib/libvcl/vcc_compile.c | 2 +- varnish-cache/lib/libvcl/vcc_token.c | 5 ++--- 4 files changed, 9 insertions(+), 10 deletions(-) diff --git a/varnish-cache/bin/varnishd/cache_acceptor.c b/varnish-cache/bin/varnishd/cache_acceptor.c index a4ffbdcd..dbd793d8 100644 --- a/varnish-cache/bin/varnishd/cache_acceptor.c +++ b/varnish-cache/bin/varnishd/cache_acceptor.c @@ -6,8 +6,8 @@ * write the session pointer to a pipe which the event engine monitors. */ -#define ACCEPTOR_USE_POLL -#undef ACCEPTOR_USE_KQUEUE +#undef ACCEPTOR_USE_POLL +#define ACCEPTOR_USE_KQUEUE #include #include diff --git a/varnish-cache/bin/varnishd/varnishd.c b/varnish-cache/bin/varnishd/varnishd.c index 7069fe2c..fdb0f0b2 100644 --- a/varnish-cache/bin/varnishd/varnishd.c +++ b/varnish-cache/bin/varnishd/varnishd.c @@ -63,8 +63,8 @@ setup_hash(const char *sflag) } else if (!cmp_hash(&hsl_slinger, sflag, p)) { hp = &hsl_slinger; } else { - fprintf(stderr, "Unknown hash method \"%*.*s\"\n", - p - sflag, p - sflag, sflag); + fprintf(stderr, "Unknown hash method \"%.*s\"\n", + (int)(p - sflag), sflag); exit (2); } heritage.hash = hp; @@ -108,8 +108,8 @@ setup_storage(const char *sflag) } else if (!cmp_storage(&smf_stevedore, sflag, p)) { stp = &smf_stevedore; } else { - fprintf(stderr, "Unknown storage method \"%*.*s\"\n", - p - sflag, p - sflag, sflag); + fprintf(stderr, "Unknown storage method \"%.*s\"\n", + (int)(p - sflag), sflag); exit (2); } heritage.stevedore = malloc(sizeof *heritage.stevedore); diff --git a/varnish-cache/lib/libvcl/vcc_compile.c b/varnish-cache/lib/libvcl/vcc_compile.c index c75c662b..b5a40765 100644 --- a/varnish-cache/lib/libvcl/vcc_compile.c +++ b/varnish-cache/lib/libvcl/vcc_compile.c @@ -420,7 +420,7 @@ HeaderVar(struct tokenlist *tl, struct token *t, struct var *vh) v->name = p; v->fmt = STRING; asprintf(&p, "VRT_GetHdr(sp, \"\\%03o%s:\")", - strlen(v->name + vh->len) + 1, v->name + vh->len); + (unsigned)(strlen(v->name + vh->len) + 1), v->name + vh->len); assert(p != NULL); v->rname = p; return (v); diff --git a/varnish-cache/lib/libvcl/vcc_token.c b/varnish-cache/lib/libvcl/vcc_token.c index b0314a93..e4c4c049 100644 --- a/varnish-cache/lib/libvcl/vcc_token.c +++ b/varnish-cache/lib/libvcl/vcc_token.c @@ -180,9 +180,8 @@ vcc_AddToken(struct tokenlist *tl, unsigned tok, const char *b, const char *e) TAILQ_INSERT_TAIL(&tl->tokens, t, list); tl->t = t; if (0) { - fprintf(stderr, "[%s %*.*s] ", - vcl_tnames[tok], - e - b, e - b, b); + fprintf(stderr, "[%s %.*s] ", + vcl_tnames[tok],(int)(e - b), b); if (tok == EOI) fprintf(stderr, "\n"); } -- 2.39.5