Commit 2df9e89e authored by Dag Erling Smørgrav's avatar Dag Erling Smørgrav

Merged revisions 1823 via svnmerge from

file:///var/lib/svn/varnish/trunk/varnish-cache

........
  r1823 | des | 2007-08-10 09:13:02 +0200 (Fri, 10 Aug 2007) | 2 lines
  
  Avoid mixing statements and declarations (#147)
........


git-svn-id: http://www.varnish-cache.org/svn/branches/1.1@1825 d4fa192b-c00b-0410-8231-f00ffab90ce4
parent 506e1ffd
...@@ -51,6 +51,7 @@ telnet_mgt(const char* T_arg, int argc, char* argv[]) ...@@ -51,6 +51,7 @@ telnet_mgt(const char* T_arg, int argc, char* argv[])
struct vss_addr **ta; struct vss_addr **ta;
char *addr, *port; char *addr, *port;
int i, n; int i, n;
int sock;
long status, bytes; long status, bytes;
char *answer = NULL; char *answer = NULL;
char buf[13]; char buf[13];
...@@ -65,7 +66,7 @@ telnet_mgt(const char* T_arg, int argc, char* argv[]) ...@@ -65,7 +66,7 @@ telnet_mgt(const char* T_arg, int argc, char* argv[])
exit(2); exit(2);
} }
int sock = VSS_connect(ta[0]); sock = VSS_connect(ta[0]);
for (i = 0; i < n; ++i) { for (i = 0; i < n; ++i) {
free(ta[i]); free(ta[i]);
......
...@@ -116,7 +116,8 @@ struct smf_sc { ...@@ -116,7 +116,8 @@ struct smf_sc {
static void static void
smf_calcsize(struct smf_sc *sc, const char *size, int newfile) smf_calcsize(struct smf_sc *sc, const char *size, int newfile)
{ {
uintmax_t l; struct statfs fsst;
uintmax_t l, fssize;
unsigned bs; unsigned bs;
char suff[2]; char suff[2];
int i, explicit; int i, explicit;
...@@ -126,10 +127,7 @@ smf_calcsize(struct smf_sc *sc, const char *size, int newfile) ...@@ -126,10 +127,7 @@ smf_calcsize(struct smf_sc *sc, const char *size, int newfile)
AN(sc); AN(sc);
AZ(fstat(sc->fd, &st)); AZ(fstat(sc->fd, &st));
#if defined(HAVE_SYS_MOUNT_H) || defined(HAVE_SYS_VFS_H)
struct statfs fsst;
AZ(fstatfs(sc->fd, &fsst)); AZ(fstatfs(sc->fd, &fsst));
#endif
/* We use units of the larger of filesystem blocksize and pagesize */ /* We use units of the larger of filesystem blocksize and pagesize */
bs = sc->pagesize; bs = sc->pagesize;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment