From 2bb750e71cc0bb04bcf7e76e0069d72c866630fb Mon Sep 17 00:00:00 2001 From: Miklos Szeredi Date: Mon, 3 Oct 2005 14:54:24 +0000 Subject: [PATCH] trailing whitespace fix --- kernel/fuse_kernel.h | 4 ++-- lib/fuse.c | 4 ++-- lib/fuse_lowlevel.c | 4 ++-- lib/fuse_mt.c | 6 +++--- lib/fuse_session.c | 6 +++--- test/test.c | 16 ++++++++-------- util/fusermount.c | 2 +- 7 files changed, 21 insertions(+), 21 deletions(-) diff --git a/kernel/fuse_kernel.h b/kernel/fuse_kernel.h index 7c4256c..1dc9e06 100644 --- a/kernel/fuse_kernel.h +++ b/kernel/fuse_kernel.h @@ -11,7 +11,7 @@ the terms of the BSD Licence as follows: Copyright (C) 2005 Miklos Szeredi. All rights reserved. - + Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -20,7 +20,7 @@ 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - + THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE diff --git a/lib/fuse.c b/lib/fuse.c index b52febb..c81fcf7 100644 --- a/lib/fuse.c +++ b/lib/fuse.c @@ -1820,11 +1820,11 @@ struct fuse *fuse_new_common(int fd, const char *opts, free(llopts); if (f->se == NULL) goto out_free; - + ch = fuse_kern_chan_new(fd); if (ch == NULL) goto out_free_session; - + fuse_session_add_chan(f->se, ch); f->ctr = 0; diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c index 09c9681..eb7996c 100644 --- a/lib/fuse_lowlevel.c +++ b/lib/fuse_lowlevel.c @@ -715,7 +715,7 @@ static void fuse_ll_process(void *data, const char *buf, size_t len, case FUSE_INIT: do_init(req, (struct fuse_init_in_out *) inarg); break; - + case FUSE_LOOKUP: do_lookup(req, in->nodeid, (char *) inarg); break; @@ -875,7 +875,7 @@ static void fuse_ll_destroy(void *data) } -struct fuse_session *fuse_lowlevel_new(const char *opts, +struct fuse_session *fuse_lowlevel_new(const char *opts, const struct fuse_lowlevel_ops *op, size_t op_size, void *userdata) { diff --git a/lib/fuse_mt.c b/lib/fuse_mt.c index accd6c4..1136ee9 100644 --- a/lib/fuse_mt.c +++ b/lib/fuse_mt.c @@ -109,13 +109,13 @@ static int mt_chan_receive(struct fuse_chan *ch, char *buf, size_t size) struct procdata *pd = (struct procdata *) fuse_chan_data(ch); assert(size >= sizeof(cmd)); - + cmd = fuse_read_cmd(pd->f); if (cmd == NULL) return 0; - + *(struct fuse_cmd **) buf = cmd; - + return sizeof(cmd); } diff --git a/lib/fuse_session.c b/lib/fuse_session.c index 5fd1fc7..f88d6e5 100644 --- a/lib/fuse_session.c +++ b/lib/fuse_session.c @@ -17,7 +17,7 @@ struct fuse_session { struct fuse_session_ops op; void *data; - + volatile int exited; struct fuse_chan *ch; @@ -31,7 +31,7 @@ struct fuse_chan { int fd; size_t bufsize; - + void *data; }; @@ -105,7 +105,7 @@ int fuse_session_exited(struct fuse_session *se) return se->exited; } -struct fuse_chan *fuse_chan_new(struct fuse_chan_ops *op, int fd, +struct fuse_chan *fuse_chan_new(struct fuse_chan_ops *op, int fd, size_t bufsize, void *data) { struct fuse_chan *ch = (struct fuse_chan *) malloc(sizeof(*ch)); diff --git a/test/test.c b/test/test.c index 3fba745..6a82467 100644 --- a/test/test.c +++ b/test/test.c @@ -550,10 +550,10 @@ static int do_test_open(int exist, int flags, const char *flags_str, int mode) res = create_file(testfile, testdata2, testdata2len); if (res == -1) return -1; - + currlen = testdata2len; } - + fd = open(testfile, flags, mode); if ((flags & O_CREAT) && (flags & O_EXCL) && exist) { if (fd != -1) { @@ -578,12 +578,12 @@ static int do_test_open(int exist, int flags, const char *flags_str, int mode) if (flags & O_TRUNC) currlen = 0; - + err += check_type(testfile, S_IFREG); if (exist) err += check_mode(testfile, 0644); else - err += check_mode(testfile, mode); + err += check_mode(testfile, mode); err += check_nlink(testfile, 1); err += check_size(testfile, currlen); if (exist && !(flags & O_TRUNC) && (mode & 0400)) @@ -602,7 +602,7 @@ static int do_test_open(int exist, int flags, const char *flags_str, int mode) currlen = datalen; err += check_size(testfile, currlen); - + if (mode & 0400) { err += check_data(testfile, data, 0, datalen); if (exist && !(flags & O_TRUNC) && testdata2len > datalen) @@ -699,7 +699,7 @@ static int do_test_open_acc(int flags, const char *flags_str, int mode, int err) PERROR("chmod"); return -1; } - + res = check_mode(testfile, mode); if (res == -1) return -1; @@ -943,7 +943,7 @@ int main(int argc, char *argv[]) } basepath = argv[1]; assert(strlen(basepath) < 512); - + sprintf(testfile, "%s/testfile", basepath); sprintf(testfile2, "%s/testfile2", basepath); sprintf(testdir, "%s/testdir", basepath); @@ -1001,7 +1001,7 @@ int main(int argc, char *argv[]) err += test_open_acc(O_RDONLY, 0000, EACCES); err += test_open_acc(O_WRONLY, 0000, EACCES); err += test_open_acc(O_RDWR, 0000, EACCES); - + unlink(testfile); unlink(testfile2); rmdir(testdir); diff --git a/util/fusermount.c b/util/fusermount.c index 0330cf9..cd98ab5 100644 --- a/util/fusermount.c +++ b/util/fusermount.c @@ -199,7 +199,7 @@ static int remove_mount(const char *mnt, int quiet, const char *mtab, strcmp(p + 5, user) == 0) removed = 1; /* /etc/mtab is a link pointing to /proc/mounts: */ - else if ((p = strstr(entp->mnt_opts, "user_id=")) && + else if ((p = strstr(entp->mnt_opts, "user_id=")) && (p == entp->mnt_opts || *(p-1) == ',') && strncmp(p + 8, uidstr, uidlen) == 0 && (*(p+8+uidlen) == ',' || *(p+8+uidlen) == '\0')) -- 2.30.2