diff --git a/drivers/input/stmpe811_base.c b/drivers/input/stmpe811_base.c index 0bdbbf23c8..f2bdf8bca8 100644 --- a/drivers/input/stmpe811_base.c +++ b/drivers/input/stmpe811_base.c @@ -339,6 +339,7 @@ STMPE811_HANDLE stmpe811_instantiate(FAR struct i2c_dev_s *dev, if (ret < 0) { #ifdef CONFIG_STMPE811_MULTIPLE + g_stmpe811list = priv->flink; kmm_free(priv); #endif return NULL;