ccanlint: fix stack smash.
authorRusty Russell <rusty@rustcorp.com.au>
Mon, 14 Jan 2013 07:40:59 +0000 (18:10 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Mon, 14 Jan 2013 07:40:59 +0000 (18:10 +1030)
commit6bab11a210f123033225553057e24e68b99a8afd
tree5819b059e533303075d1bea6a6fd7803208790fc
parentbc1ebe804ee892ef18eef1b48589c50c14230dd3
ccanlint: fix stack smash.

"engla" on IRC reported that ccanlint on linux/powerpc would loop
infinitely calling dep_failed after all tests are run and the score is
output.

Reproduced, and discovered that cannot_run() takes a container_of(),
except our top node is not a struct ccanlint.  The result was harmless on
x86, but set dep_failed to the return address on powerpc, causing that
to be called repeatedly.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
tools/ccanlint/ccanlint.c