Diff

Differences From Artifact [616c3164a5]:

To Artifact [71ddae3095]:


714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733

734
735
736
737
738
739
740
...
777
778
779
780
781
782
783






784
785
786
787
788
789
790

	return(TCL_OK);
}

/*
 * FUSE operations structure
 */
static struct fuse_operations appfs_oper = {
	.getattr   = appfs_fuse_getattr,
	.readdir   = appfs_fuse_readdir,
	.readlink  = appfs_fuse_readlink,
	.open      = appfs_fuse_open,
	.release   = appfs_fuse_close,
	.read      = appfs_fuse_read
};

/*
 * Entry point into this program.
 */
int main(int argc, char **argv) {

	const char *cachedir = APPFS_CACHEDIR;
	int pthread_ret;

	/*
	 * Set global variables, these should be configuration options.
	 */
	globalThread.cachedir = cachedir;
................................................................................
	 * Tcl mode, for running raw Tcl in the same environment AppFSd would
	 * run code.
	 */
	if (argc == 3 && strcmp(argv[1], "-tcl") == 0) {
		return(appfs_tcl(argv[2]));
	}







	/*
	 * Enter the FUSE main loop -- this will process any arguments
	 * and start servicing requests.
	 */
	return(fuse_main(argc, argv, &appfs_oper, NULL));
}
 







|












>







 







>
>
>
>
>
>




|


714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
...
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797

	return(TCL_OK);
}

/*
 * FUSE operations structure
 */
static struct fuse_operations appfs_operations = {
	.getattr   = appfs_fuse_getattr,
	.readdir   = appfs_fuse_readdir,
	.readlink  = appfs_fuse_readlink,
	.open      = appfs_fuse_open,
	.release   = appfs_fuse_close,
	.read      = appfs_fuse_read
};

/*
 * Entry point into this program.
 */
int main(int argc, char **argv) {
	struct fuse_args args = FUSE_ARGS_INIT(argc, argv);
	const char *cachedir = APPFS_CACHEDIR;
	int pthread_ret;

	/*
	 * Set global variables, these should be configuration options.
	 */
	globalThread.cachedir = cachedir;
................................................................................
	 * Tcl mode, for running raw Tcl in the same environment AppFSd would
	 * run code.
	 */
	if (argc == 3 && strcmp(argv[1], "-tcl") == 0) {
		return(appfs_tcl(argv[2]));
	}

	/*
	 * Add FUSE arguments which we always supply
	 */
	fuse_opt_parse(&args, NULL, NULL, NULL);
	fuse_opt_add_arg(&args, "-odefault_permissions,fsname=appfs,use_ino,kernel_cache,entry_timeout=60,attr_timeout=3600,intr,big_writes");

	/*
	 * Enter the FUSE main loop -- this will process any arguments
	 * and start servicing requests.
	 */
	return(fuse_main(args.argc, args.argv, &appfs_operations, NULL));
}