Commit ca75f9be authored by Federico Vaga's avatar Federico Vaga

check device pointer before register it

Signed-off-by: Federico Vaga's avatarFederico Vaga <federico.vaga@cern.ch>
parent d952f5c0
......@@ -1223,6 +1223,9 @@ int zio_register_device(struct zio_device *zdev, const char *name,
{
int n_conflict;
if (!zdev)
return -EINVAL;
/* Verify if it is a valid name */
n_conflict = zobj_unique_name(&zstat->all_devices, name);
if (n_conflict < 0)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment