Hi,

On Mon, 2016-02-01 at 22:05 +0100, Peter Spiess-Knafl wrote:
> I just took a look at the failing build logs. It seems that the linking
> step gets killed after 150 minutes. I can reproduce it on a Raspbian I
> have locally running.
> 
> Do you have any idea how to fix this?

It's not the link step that fails in the build logs, it's the help2man
call. help2man runs 'nordlicht --help' which never terminates.

From main.c:
>     char c;
> 
>     // The next line leaks 3 bytes, blame popt!
>     while ((c = poptGetNextOpt(popt)) >= 0) { }

But 'char' is unsigned on arm so the while condition is always true. If
nordlicht was compiled with -Wall, gcc would tell you about this:

> ../main.c: In function 'main':
> ../main.c:112:39: warning: comparison is always true due to limited
> range of data type [-Wtype-limits]
>      while ((c = poptGetNextOpt(popt)) >= 0) { }
>                                        ^
> ../main.c:114:11: warning: comparison is always false due to limited
> range of data type [-Wtype-limits]
>      if (c < -1) {
>            ^

James

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to