Considering it's also used below (line 112), I think we should introduce
```go
func DeferredClose(err *error, closer io.Closer) {
    closeErr := rdc.Close()
    if *err == nil {
        *err == closeErr
    }
}
```
and use that for the defer. The function does not bind local vars, it gets passed a pointer. It's shorter and more general.