Changeset 98abd40 in mainline for uspace/app/bdsh/cmds


Ignore:
Timestamp:
2013-07-06T21:57:22Z (13 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
c8bb1633, cdc8a391
Parents:
b8e72fd1 (diff), 507c6f3 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes

Location:
uspace/app/bdsh/cmds/modules
Files:
4 deleted
5 edited

Legend:

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

    rb8e72fd1 r98abd40  
    9898        builtin_t *cmd;
    9999        module_t *mod;
    100         unsigned int i;
    101100
    102101        printf("\n  Bdsh built-in commands:\n");
     
    104103
    105104        /* First, show a list of built in commands that are available in this mode */
    106         for (cmd = builtins; cmd->name != NULL; cmd++, i++) {
     105        for (cmd = builtins; cmd->name != NULL; cmd++) {
    107106                        if (is_builtin_alias(cmd->name))
    108107                                printf("   %-16s\tAlias for `%s'\n", cmd->name,
     
    112111        }
    113112
    114         i = 0;
    115 
    116113        /* Now, show a list of module commands that are available in this mode */
    117         for (mod = modules; mod->name != NULL; mod++, i++) {
     114        for (mod = modules; mod->name != NULL; mod++) {
    118115                        if (is_module_alias(mod->name))
    119116                                printf("   %-16s\tAlias for `%s'\n", mod->name,
  • uspace/app/bdsh/cmds/modules/modules.h

    rb8e72fd1 r98abd40  
    5050#include "mkfile/entry.h"
    5151#include "rm/entry.h"
    52 #include "bdd/entry.h"
    5352#include "cat/entry.h"
    5453#include "touch/entry.h"
     
    7473#include "mkfile/mkfile_def.h"
    7574#include "rm/rm_def.h"
    76 #include "bdd/bdd_def.h"
    7775#include "cat/cat_def.h"
    7876#include "touch/touch_def.h"
  • uspace/app/bdsh/cmds/modules/pwd/pwd.c

    rb8e72fd1 r98abd40  
    5555        }
    5656
    57         memset(buff, 0, sizeof(buff));
     57        memset(buff, 0, PATH_MAX);
    5858        getcwd(buff, PATH_MAX);
    5959
  • uspace/app/bdsh/cmds/modules/rm/rm.c

    rb8e72fd1 r98abd40  
    9999        if (NULL == (rm->nwd = (char *) malloc(PATH_MAX)))
    100100                return 0;
    101         memset(rm->nwd, 0, sizeof(rm->nwd));
     101        memset(rm->nwd, 0, PATH_MAX);
    102102
    103103        if (NULL == (rm->owd = (char *) malloc(PATH_MAX)))
    104104                return 0;
    105         memset(rm->owd, 0, sizeof(rm->owd));
     105        memset(rm->owd, 0, PATH_MAX);
    106106
    107107        if (NULL == (rm->cwd = (char *) malloc(PATH_MAX)))
    108108                return 0;
    109         memset(rm->cwd, 0, sizeof(rm->cwd));
     109        memset(rm->cwd, 0, PATH_MAX);
    110110
    111111        chdir(".");
     
    298298                        break;
    299299                }
    300                 memset(buff, 0, sizeof(buff));
     300                memset(buff, 0, len);
    301301                snprintf(buff, len, "%s", argv[i]);
    302302
  • uspace/app/bdsh/cmds/modules/sleep/sleep.c

    rb8e72fd1 r98abd40  
    6767        uint64_t whole_seconds;
    6868        uint64_t frac_seconds;
    69         char *endptr;
     69        const char *endptr;
    7070
    7171        /* Check for whole seconds */
Note: See TracChangeset for help on using the changeset viewer.