Skip to content

Commit

Permalink
Remove unused n variable.
Browse files Browse the repository at this point in the history
Presumably this did something at some point, but it is never read.
  • Loading branch information
zenhack committed Jun 30, 2023
1 parent 7e1bedd commit 5c0a14e
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions rpc/export.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,23 +88,19 @@ func (c *lockedConn) releaseExport(id exportID, count uint32) (capnp.ClientSnaps
}

func (c *lockedConn) releaseExportRefs(dq *deferred.Queue, refs map[exportID]uint32) error {
n := len(refs)
var firstErr error
for id, count := range refs {
snapshot, err := c.releaseExport(id, count)
if err != nil {
if firstErr == nil {
firstErr = err
}
n--
continue
}
if (snapshot == capnp.ClientSnapshot{}) {
n--
continue
}
dq.Defer(snapshot.Release)
n--
}
return firstErr
}
Expand Down

0 comments on commit 5c0a14e

Please sign in to comment.