Changeset 1772 in MondoRescue for branches/2.2.5


Ignore:
Timestamp:
Nov 6, 2007, 9:23:18 PM (16 years ago)
Author:
Bruno Cornec
Message:

Update mindi-busybox to 1.7.3

Location:
branches/2.2.5/mindi-busybox
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.5/mindi-busybox/Makefile

    r1768 r1772  
    11VERSION = 1
    22PATCHLEVEL = 7
    3 SUBLEVEL = 2
     3SUBLEVEL = 3
    44EXTRAVERSION = -rPBREV
    55NAME = Unnamed
  • branches/2.2.5/mindi-busybox/coreutils/tail.c

    r1765 r1772  
    4848{
    4949    ssize_t r;
    50     off_t current, end;
     50    off_t current;
    5151    struct stat sbuf;
    5252
    53     end = current = lseek(fd, 0, SEEK_CUR);
    54     if (!fstat(fd, &sbuf))
    55         end = sbuf.st_size;
    56     lseek(fd, end < current ? 0 : current, SEEK_SET);
     53    /* (A good comment is missing here) */
     54    current = lseek(fd, 0, SEEK_CUR);
     55    /* /proc files report zero st_size, don't lseek them. */
     56    if (fstat(fd, &sbuf) == 0 && sbuf.st_size)
     57        if (sbuf.st_size < current)
     58            lseek(fd, 0, SEEK_SET);
     59
    5760    r = safe_read(fd, buf, count);
    5861    if (r < 0) {
     
    6871static unsigned eat_num(const char *p)
    6972{
    70     if (*p == '-') p++;
    71     else if (*p == '+') { p++; G.status = EXIT_FAILURE; }
     73    if (*p == '-')
     74        p++;
     75    else if (*p == '+') {
     76        p++;
     77        G.status = EXIT_FAILURE;
     78    }
    7279    return xatou_sfx(p, tail_suffixes);
    7380}
  • branches/2.2.5/mindi-busybox/include/libbb.h

    r1765 r1772  
    777777extern void change_identity(const struct passwd *pw);
    778778extern const char *change_identity_e2str(const struct passwd *pw);
    779 extern void run_shell(const char *shell, int loginshell, const char *command, const char **additional_args);
     779extern void run_shell(const char *shell, int loginshell, const char *command, const char **additional_args) ATTRIBUTE_NORETURN;
    780780#if ENABLE_SELINUX
    781781extern void renew_current_security_context(void);
  • branches/2.2.5/mindi-busybox/networking/httpd.c

    r1765 r1772  
    11861186     * and send it to the peer. So please no SIGPIPEs! */
    11871187    signal(SIGPIPE, SIG_IGN);
     1188
     1189    /* Accound for POSTDATA already in hdr_buf */
     1190    bodyLen -= hdr_cnt;
    11881191
    11891192    /* This loop still looks messy. What is an exit criteria?
  • branches/2.2.5/mindi-busybox/networking/inetd.c

    r1765 r1772  
    735735    /* goto more; */
    736736
    737     sep->se_server = xxstrdup(skip(&cp));
     737    arg = skip(&cp);
     738    sep->se_server = xxstrdup(arg);
    738739    if (strcmp(sep->se_server, "internal") == 0) {
    739740#ifdef INETD_FEATURE_ENABLED
     
    760761#endif
    761762    argc = 0;
    762     for (arg = skip(&cp); cp; arg = skip(&cp)) {
     763    for (; cp; arg = skip(&cp)) {
    763764        if (argc < MAXARGV)
    764765            sep->se_argv[argc++] = xxstrdup(arg);
  • branches/2.2.5/mindi-busybox/networking/libiproute/iptunnel.c

    r1765 r1772  
    242242            NEXT_ARG();
    243243            key = index_in_strings(keywords, *argv);
    244             if (key == ARG_any)
     244            if (key != ARG_any)
    245245                p->iph.daddr = get_addr32(*argv);
    246246        } else if (key == ARG_local) {
    247247            NEXT_ARG();
    248248            key = index_in_strings(keywords, *argv);
    249             if (key == ARG_any)
     249            if (key != ARG_any)
    250250                p->iph.saddr = get_addr32(*argv);
    251251        } else if (key == ARG_dev) {
  • branches/2.2.5/mindi-busybox/shell/ash.c

    r1765 r1772  
    43804380/* Lives far away from here, needed for forkchild */
    43814381static void closescript(void);
     4382
    43824383/* Called after fork(), in child */
    43834384static void
     
    44244425        setsignal(SIGTERM);
    44254426    }
    4426 #if JOBS
    4427     /* For "jobs | cat" to work like in bash, we must retain list of jobs
    4428      * in child, but we do need to remove ourself */
    4429     if (jp)
    4430         freejob(jp);
    4431 #else
    44324427    for (jp = curjob; jp; jp = jp->prev_job)
    44334428        freejob(jp);
    4434 #endif
    44354429    jobless = 0;
    44364430}
  • branches/2.2.5/mindi-busybox/sysklogd/logger.c

    r1765 r1772  
    108108    if (!argc) {
    109109#define strbuf bb_common_bufsiz1
    110         while (fgets(strbuf, BUFSIZ, stdin)) {
     110        while (fgets(strbuf, COMMON_BUFSIZE, stdin)) {
    111111            if (strbuf[0]
    112112             && NOT_LONE_CHAR(strbuf, '\n')
     
    118118    } else {
    119119        char *message = NULL;
    120         int len = 1; /* for NUL */
     120        int len = 0;
    121121        int pos = 0;
    122122        do {
    123123            len += strlen(*argv) + 1;
    124             message = xrealloc(message, len);
     124            message = xrealloc(message, len + 1);
    125125            sprintf(message + pos, " %s", *argv),
    126126            pos = len;
Note: See TracChangeset for help on using the changeset viewer.