svn commit: trunk/buildroot/package/busybox
Author: jacmet
Date: 2008-04-28 23:53:55 -0700 (Mon, 28 Apr 2008) New Revision: 21892
Log:
busybox: 1.10.1 patches
Added:
trunk/buildroot/package/busybox/busybox-1.10.1-completion.patch trunk/buildroot/package/busybox/busybox-1.10.1-ioctl.patch trunk/buildroot/package/busybox/busybox-1.10.1-mdev.patch trunk/buildroot/package/busybox/busybox-1.10.1-pidof.patch trunk/buildroot/package/busybox/busybox-1.10.1-ssd.patch trunk/buildroot/package/busybox/busybox-1.10.1-taskset.patch
Changeset:
Added: trunk/buildroot/package/busybox/busybox-1.10.1-completion.patch
===================================================================
buildroot/package/busybox/busybox-1.10.1-completion.patch +57 -0
@@ -0,0 +1,57 @@ +--- busybox-1.10.1/libbb/lineedit.c Sat Apr 19 05:50:33 2008 ++++ busybox-1.10.1-completion/libbb/lineedit.c Thu Apr 24 06:45:39 2008 +@@ -518,8 +518,8 @@ + + for (i = 0; i < npaths; i++) { + dir = opendir(paths[i]); +- if (!dir) /* Don't print an error */ +- continue; ++ if (!dir) ++ continue; /* don't print an error */ + + while ((next = readdir(dir)) != NULL) { + int len1; +@@ -529,18 +529,21 @@ + if (strncmp(str_found, pfind, strlen(pfind))) + continue; + /* not see .name without .match */ +- if (*str_found == '.' && *pfind == 0) { ++ if (*str_found == '.' && *pfind == '\0') { + if (NOT_LONE_CHAR(paths[i], '/') || str_found[1]) + continue; + str_found = ""; /* only "/" */ + } + found = concat_path_file(paths[i], str_found); +- /* hmm, remover in progress? */ +- if (lstat(found, &st) < 0) ++ /* hmm, remove in progress? */ ++ /* NB: stat() first so that we see is it a directory; ++ * but if that fails, use lstat() so that ++ * we still match dangling links */ ++ if (stat(found, &st) && lstat(found, &st)) + goto cont; + /* find with dirs? */ + if (paths[i] != dirbuf) +- strcpy(found, next->d_name); /* only name */ ++ strcpy(found, next->d_name); /* only name */ + + len1 = strlen(found); + found = xrealloc(found, len1 + 2); +@@ -548,7 +551,7 @@ + found[len1+1] = '\0'; + + if (S_ISDIR(st.st_mode)) { +- /* name is directory */ ++ /* name is a directory */ + if (found[len1-1] != '/') { + found[len1] = '/'; + } +@@ -566,7 +569,7 @@ + closedir(dir); + } + if (paths != path1) { +- free(paths[0]); /* allocated memory only in first member */ ++ free(paths[0]); /* allocated memory is only in first member */ + free(paths); + } + #undef dirbuf
Added: trunk/buildroot/package/busybox/busybox-1.10.1-ioctl.patch
===================================================================
buildroot/package/busybox/busybox-1.10.1-ioctl.patch +79 -0
79 lines not on this page · raw message
Added: trunk/buildroot/package/busybox/busybox-1.10.1-mdev.patch
===================================================================
buildroot/package/busybox/busybox-1.10.1-mdev.patch +510 -0
510 lines not on this page · raw message
Added: trunk/buildroot/package/busybox/busybox-1.10.1-pidof.patch
===================================================================
buildroot/package/busybox/busybox-1.10.1-pidof.patch +11 -0
@@ -0,0 +1,11 @@ +--- busybox-1.10.1/libbb/procps.c Sat Apr 19 05:50:33 2008 ++++ busybox-1.10.1-pidof/libbb/procps.c Sat Apr 26 01:18:32 2008 +@@ -258,7 +258,7 @@ + &sp->start_time, + &vsz, + &rss); +- if (n != 10) ++ if (n != 11) + break; + /* vsz is in bytes and we want kb */ + sp->vsz = vsz >> 10;
Added: trunk/buildroot/package/busybox/busybox-1.10.1-ssd.patch
===================================================================
buildroot/package/busybox/busybox-1.10.1-ssd.patch +187 -0
187 lines not on this page · raw message
Added: trunk/buildroot/package/busybox/busybox-1.10.1-taskset.patch
===================================================================
buildroot/package/busybox/busybox-1.10.1-taskset.patch +14 -0
@@ -0,0 +1,14 @@ +--- busybox-1.10.1/miscutils/taskset.c Sat Apr 19 06:03:13 2008 ++++ busybox-1.10.1-taskset/miscutils/taskset.c Fri Apr 25 18:58:53 2008 +@@ -94,8 +94,10 @@ + unsigned i; + /* Do not allow zero mask: */ + unsigned long long m = xstrtoull_range(aff, 0, 1, ULLONG_MAX); ++ enum { CNT_BIT = CPU_SETSIZE < sizeof(m)*8 ? CPU_SETSIZE : sizeof(m)*8 }; ++ + CPU_ZERO(&mask); +- for (i = 0; i < CPU_SETSIZE; i++) { ++ for (i = 0; i < CNT_BIT; i++) { + unsigned long long bit = (1ULL << i); + if (bit & m) + CPU_SET(i, &mask);