89a07f6033b3f31aef2aa08c0e80e3cc56c35bff
Since commit e9b9e4ace294230c6b8eb has landed, there is a chance that container.RWLayer is nil (due to some half-removed container). Let's check the pointer before use to avoid any potential nil pointer dereferences, resulting in a daemon crash. Note that even without the abovementioned commit, it's better to perform an extra check (even it's totally redundant) rather than to have a possibility of a daemon crash. In other words, better be safe than sorry. [v2: add a test case for daemon.getInspectData] [v3: add a check for container.Dead and a special error for the case] Fixes: e9b9e4ace294230c6b8eb Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com> Upstream-commit: 195893d38160c0893e326b8674e05ef6714aeaa4 Component: engine
Description
No description provided
310 MiB
Languages
Go
92%
Shell
5.5%
Dockerfile
1.1%
Go-Checksums
0.9%
Makefile
0.3%
Other
0.2%