mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-09-29 08:00:26 +09:00
video: truetype: Fix a memory leak on error
When the resolution is not supported we should free the memory we don't plan to use. Reported-by: Coverity (CID: 135127) Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
595af9db24
commit
f6e75ba7fe
@ -289,6 +289,7 @@ static int console_truetype_putc_xy(struct udevice *dev, uint x, uint y,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
|
free(data);
|
||||||
return -ENOSYS;
|
return -ENOSYS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user