diff --git a/hw/9pfs/9p.c b/hw/9pfs/9p.c index 55821343e59475ee768f7c8ca029db1b69c039e9..289d00b01acf77661ae3505941ab4d55b0a4e9ac 100644 --- a/hw/9pfs/9p.c +++ b/hw/9pfs/9p.c @@ -498,9 +498,9 @@ static int coroutine_fn v9fs_mark_fids_unreclaim(V9fsPDU *pdu, V9fsPath *path) { int err; V9fsState *s = pdu->s; - V9fsFidState *fidp, head_fid; + V9fsFidState *fidp; - head_fid.next = s->fid_list; +again: for (fidp = s->fid_list; fidp; fidp = fidp->next) { if (fidp->path.size != path->size) { continue; @@ -520,7 +520,7 @@ static int coroutine_fn v9fs_mark_fids_unreclaim(V9fsPDU *pdu, V9fsPath *path) * switched to the worker thread */ if (err == 0) { - fidp = &head_fid; + goto again; } } }