fuse: simplify unique ctr
Since it's a 64bit counter, it's never gonna wrap around. Remove code dealing with that possibility. Signed-off-by: Miklos Szeredi <mszeredi@suse.cz> Reviewed-by: Ashish Samant <ashish.samant@oracle.com>
This commit is contained in:
@@ -319,12 +319,7 @@ static unsigned len_args(unsigned numargs, struct fuse_arg *args)
|
||||
|
||||
static u64 fuse_get_unique(struct fuse_conn *fc)
|
||||
{
|
||||
fc->reqctr++;
|
||||
/* zero is special */
|
||||
if (fc->reqctr == 0)
|
||||
fc->reqctr = 1;
|
||||
|
||||
return fc->reqctr;
|
||||
return ++fc->reqctr;
|
||||
}
|
||||
|
||||
static void queue_request(struct fuse_conn *fc, struct fuse_req *req)
|
||||
|
Reference in New Issue
Block a user