link-mso19: Prevent double free errors when freeing sdi->priv.

This commit is contained in:
Renato Caldas 2012-01-18 16:03:39 +00:00
parent 357285a944
commit e084a8042e
1 changed files with 3 additions and 0 deletions

View File

@ -530,7 +530,10 @@ static void hw_cleanup(void)
if (sdi->serial->fd != -1)
serial_close(sdi->serial->fd);
if (sdi->priv != NULL)
{
free(sdi->priv);
sdi->priv = NULL;
}
sr_device_instance_free(sdi);
}
g_slist_free(device_instances);