From: Miklos Szeredi Date: Thu, 9 Sep 2004 08:44:01 +0000 (+0000) Subject: fix X-Git-Tag: fuse_1_9~16 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=8b2d3333b37d74887b090a280fe98b8cbed46b4e;p=qemu-gpiodev%2Flibfuse.git fix --- diff --git a/ChangeLog b/ChangeLog index a1f4ab1..fe8eb6b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2004-09-09 Miklos Szeredi + + * Fix bug in case two FORGETs for the same node are executed in + the wrong order. Bug spotted and endured for months by Franco + Broi, and logfile for solution provided by Terje Oseberg + 2004-09-01 Miklos Szeredi * Add -D_REENTRANT to the compile flags diff --git a/lib/fuse.c b/lib/fuse.c index 671fbcc..6c998c3 100644 --- a/lib/fuse.c +++ b/lib/fuse.c @@ -317,8 +317,8 @@ static void destroy_node(struct fuse *f, fino_t ino, int version) struct node *node; pthread_mutex_lock(&f->lock); - node = get_node(f, ino); - if (node->version == version && ino != FUSE_ROOT_INO) { + node = __get_node(f, ino); + if (node && node->version == version && ino != FUSE_ROOT_INO) { unhash_name(f, node); unhash_ino(f, node); free_node(node);