According to bug #63, crond is unhappy with crontab lines that don't end in a newline, or lines that have trailing spaces.
This commit was genuinely broken at the time (not related to our build system): scripts/config/mkconfigs.c (2005-08-01 - 2006-10-05 arasi) uretilen bbconfigopts.h icine .config satirlarini kacissiz, ham newline'larla gömüyordu - gecerli C degildi, busybox'un kendi bb_mkdep araci bile parse edemiyordu (7d219aab7 ile duzeltildi, mkconfigs shell scripte cevrildi)
No binary (build failed)
—
(log yok)
| @@ -29,14 +29,18 @@ | |
| void trim(char *s) | |
| { | |
| - | int len = strlen(s); |
| + | size_t len = strlen(s); |
| + | size_t lws; |
| /* trim trailing whitespace */ | |
| - | while ( len > 0 && isspace(s[len-1])) |
| - | s[--len]='\0'; |
| + | while (len && isspace(s[len-1])) --len; |
| /* trim leading whitespace */ | |
| - | memmove(s, &s[strspn(s, " \n\r\t\v")], len); |
| + | if(len) { |
| + | lws = strspn(s, " \n\r\t\v"); |
| + | memmove(s, s + lws, len -= lws); |
| + | } |
| + | s[len] = 0; |
| } | |
| /* END CODE */ | |
| @@ -589,10 +589,8 @@ static void SynchronizeFile(const char *fileName) | |
| CronLine line; | |
| char *ptr; | |
| - | if (buf[0]) { |
| - | buf[strlen(buf) - 1] = 0; |
| - | } |
| - | if (buf[0] == 0 || buf[0] == '#' || buf[0] == ' ' || buf[0] == '\t') { |
| + | trim(buf); |
| + | if (buf[0] == 0 || buf[0] == '#') { |
| continue; | |
| } | |
| if (--maxEntries == 0) { | |