fix --block handling with invalid paths
The rootdev program was printing the path buffer even when the library
call failed. In that case, the buffer most likely is uninitialized.
Make sure we seed it with a NUL byte so it's always valid.
TEST=`FEATURES=test emerge-link rootdev` passes
Trybot-Ready: Mike Frysinger <email@example.com>
Reviewed-by: Yunlian Jiang <firstname.lastname@example.org>
Commit-Queue: Mike Frysinger <email@example.com>
Tested-by: Mike Frysinger <firstname.lastname@example.org>
1 file changed