tests: fix a potential segfault
authorBartosz Golaszewski <bartekgola@gmail.com>
Mon, 12 Jun 2017 09:01:52 +0000 (11:01 +0200)
committerBartosz Golaszewski <bartekgola@gmail.com>
Mon, 12 Jun 2017 09:01:52 +0000 (11:01 +0200)
commit45a60afb1639c7f9545664d403ab97f770107bca
tree3419c69565a6e4bfc8fc2d4c9816962e0650b24f
parent4348a31039163417a5017ac4bc0f872df4e5a4fe
tests: fix a potential segfault

A string passed to test_free_str() must be allocated by malloc() or
NULL, so we need to initialize ptrn.

Signed-off-by: Bartosz Golaszewski <bartekgola@gmail.com>
tests/tests-gpioinfo.c