mirror of
				https://github.com/optim-enterprises-bv/vault.git
				synced 2025-10-31 18:48:08 +00:00 
			
		
		
		
	Fix panic when unwrapping if the server EOFs
This commit is contained in:
		| @@ -135,9 +135,10 @@ func (c *Logical) Unwrap(wrappingToken string) (*Secret, error) { | ||||
| 	} | ||||
|  | ||||
| 	resp, err := c.c.RawRequest(r) | ||||
| 	if resp != nil { | ||||
| 		defer resp.Body.Close() | ||||
| 	if resp == nil { | ||||
| 		return nil, nil | ||||
| 	} | ||||
| 	defer resp.Body.Close() | ||||
| 	if err != nil && resp.StatusCode != 404 { | ||||
| 		return nil, err | ||||
| 	} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Jeff Mitchell
					Jeff Mitchell