Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/bdsh/cmds/modules/touch/touch.c

    r9d58539 r6afc9d7  
    9090        DIR *dirp;
    9191       
    92         for (c = 0, optind = 0, longind = 0; c != -1; ) {
     92        for (c = 0, optreset = 1, optind = 0, longind = 0; c != -1; ) {
    9393                c = getopt_long(argc, argv, "c", long_options, &longind);
    9494                switch (c) {
     
    123123               
    124124                /* Check whether file exists if -c (--no-create) option is given */
    125                 if ((!no_create) || ((no_create) && (stat(buff, &file_stat) == EOK)))
     125                if ((!no_create) || ((no_create) && (stat(buff, &file_stat) == 0)))
    126126                        fd = open(buff, O_RDWR | O_CREAT);
    127127               
Note: See TracChangeset for help on using the changeset viewer.