mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-11 19:00:02 +01:00
Return suspended status also for unknow target types.
This patch allows dm_status_suspended() to report if device is suspended or not also for unknown target types from libcryptsetup perspective (e.g.: dm-cache).
This commit is contained in:
committed by
Milan Broz
parent
7d7b3d87c2
commit
44b8dd8cb1
@@ -1897,7 +1897,7 @@ int dm_status_suspended(struct crypt_device *cd, const char *name)
|
||||
r = dm_status_dmi(name, &dmi, NULL, NULL);
|
||||
dm_exit_context();
|
||||
|
||||
if (r < 0)
|
||||
if (r < 0 && r != -EEXIST)
|
||||
return r;
|
||||
|
||||
return dmi.suspended ? 1 : 0;
|
||||
|
||||
Reference in New Issue
Block a user