+2006-12-04 Miklos Szeredi <miklos@szeredi.hu>
+
+ * Fix warnings with gcc-4.1 on 64bit archs. Report from
+ Harshavardhana
+
+ * Add extra warning options, and fix resulting warnings
+
+ * Really fix fuse_teardown problem
+
2006-12-02 Miklos Szeredi <miklos@szeredi.hu>
* Add -lrt to fuse.pc (if needed) to fix static linking against
esac
if test "$ac_env_CFLAGS_set" != set; then
- CFLAGS="-Wall -W -g -O2"
+ CFLAGS="-Wall -W -Wno-sign-compare -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -g -O2 -fno-strict-aliasing"
fi
AC_ARG_ENABLE(kernel-module,
fuse_main_real_compat25(argc, argv, op, sizeof(*(op)))
# define fuse_new fuse_new_compat25
# define fuse_setup fuse_setup_compat25
-# define fuse_teardown fuse_teardown_compat25
+# define fuse_teardown fuse_teardown_compat22
# define fuse_operations fuse_operations_compat25
# elif FUSE_USE_VERSION == 22
# define fuse_main(argc, argv, op) \
fuse_main_real_compat22(argc, argv, op, sizeof(*(op)))
# define fuse_new fuse_new_compat22
# define fuse_setup fuse_setup_compat22
-# define fuse_teardown fuse_teardown_compat25
+# define fuse_teardown fuse_teardown_compat22
# define fuse_operations fuse_operations_compat22
# define fuse_file_info fuse_file_info_compat
# elif FUSE_USE_VERSION == 24
# define fuse_main fuse_main_compat2
# define fuse_new fuse_new_compat2
# define __fuse_setup fuse_setup_compat2
-# define __fuse_teardown fuse_teardown_compat25
+# define __fuse_teardown fuse_teardown_compat22
# define __fuse_exited fuse_exited
# define __fuse_set_getcontext_func fuse_set_getcontext_func
# else
size_t op_size, char **mountpoint,
int *multithreaded, int *fd);
-void fuse_teardown_compat25(struct fuse *fuse, int fd, char *mountpoint);
+void fuse_teardown_compat22(struct fuse *fuse, int fd, char *mountpoint);
#ifndef __FreeBSD__
#include <sys/statfs.h>
#include "fuse_lowlevel.h"
#include "fuse_kernel.h"
+#include "fuse_i.h"
#include <stdio.h>
#include <errno.h>
#include "fuse_opt.h"
#include "fuse_i.h"
#include "fuse_misc.h"
+#include "fuse_common_compat.h"
+#include "fuse_lowlevel_compat.h"
#include <stdio.h>
#include <stdlib.h>
}
if (bufsize < FUSE_MIN_READ_BUFFER) {
- fprintf(stderr, "fuse: warning: buffer size too small: %i\n", bufsize);
+ fprintf(stderr, "fuse: warning: buffer size too small: %zu\n",
+ bufsize);
bufsize = FUSE_MIN_READ_BUFFER;
}
struct fuse_req *req;
if (f->debug) {
- printf("unique: %llu, opcode: %s (%i), nodeid: %lu, insize: %i\n",
+ printf("unique: %llu, opcode: %s (%i), nodeid: %lu, insize: %zu\n",
(unsigned long long) in->unique,
opname((enum fuse_opcode) in->opcode), in->opcode,
(unsigned long) in->nodeid, len);
}
-#include "fuse_common_compat.h"
-#include "fuse_lowlevel_compat.h"
-
#ifndef __FreeBSD__
static void fill_open_compat(struct fuse_open_out *arg,
}
#undef fuse_main
+int fuse_main(void);
int fuse_main(void)
{
fprintf(stderr, "fuse_main(): This function does not exist\n");
#include "config.h"
#include "fuse_i.h"
#include "fuse_opt.h"
+#include "fuse_common_compat.h"
#include <stdio.h>
#include <stdlib.h>
filenames. */
static int check_name(const char *name)
{
- char *s;
+ const char *s;
for (s = "\n\t\\"; *s; s++) {
if (strchr(name, *s)) {
fprintf(stderr, "%s: illegal character 0x%02x in mount entry\n",