intel / libyami-utils

Libyami Utilities
Apache License 2.0
24 stars 45 forks source link

tests/decodeoutput: initialize m_file pointer to NULL #98

Closed uartie closed 7 years ago

uartie commented 7 years ago

m_file member pointer is not initialized and will get an arbitrary value. If that arbitrary value is not 0, then it fools code like "if(m_file)" into thinking it's ok to use m_file.

Thus, ensure m_file is initialized to NULL in constructor.

Fixes 01org/libyami#743

Signed-off-by: U. Artie Eoff ullysses.a.eoff@intel.com

wudping commented 7 years ago

Thanks @uartie for fixing the bug.

wudping commented 7 years ago

+1

wudping commented 7 years ago

verify + 1