Ignore:
Timestamp:
Jan 1, 2014, 12:47:38 AM (7 years ago)
Author:
Bruno Cornec
Message:
  • Update mindi-busybox to 1.21.1
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.2/mindi-busybox/coreutils/basename.c

    r2725 r3232  
    2929//config:     to enable the 'basename' utility.
    3030
     31//usage:#define basename_trivial_usage
     32//usage:       "FILE [SUFFIX]"
     33//usage:#define basename_full_usage "\n\n"
     34//usage:       "Strip directory path and .SUFFIX from FILE\n"
     35//usage:
     36//usage:#define basename_example_usage
     37//usage:       "$ basename /usr/local/bin/foo\n"
     38//usage:       "foo\n"
     39//usage:       "$ basename /usr/local/bin/\n"
     40//usage:       "bin\n"
     41//usage:       "$ basename /foo/bar.txt .txt\n"
     42//usage:       "bar"
     43
    3144#include "libbb.h"
    3245
     
    3851    size_t m, n;
    3952    char *s;
     53
     54    if (argv[1] && strcmp(argv[1], "--") == 0) {
     55        argv++;
     56        argc--;
     57    }
    4058
    4159    if ((unsigned)(argc-2) >= 2) {
Note: See TracChangeset for help on using the changeset viewer.