Changeset 3bacee1 in mainline for uspace/app/bdsh


Ignore:
Timestamp:
2018-04-12T16:27:17Z (6 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
3cf22f9
Parents:
76d0981d
git-author:
Jiri Svoboda <jiri@…> (2018-04-11 19:25:33)
git-committer:
Jiri Svoboda <jiri@…> (2018-04-12 16:27:17)
Message:

Make ccheck-fix again and commit more good files.

Location:
uspace/app/bdsh
Files:
2 edited

Legend:

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

    r76d0981d r3bacee1  
    5959                help_cmd_cmp(HELP_SHORT);
    6060                printf(
    61                 "Usage:  %s [options] <file1> <file2>\n"
    62                 "Options:\n"
    63                 "  -h, --help       A short option summary\n"
    64                 "  -v, --version    Print version information and exit\n"
    65                 "No output is printed; the return code is 1 if the files differ.\n",
    66                 cmdname);
     61                    "Usage:  %s [options] <file1> <file2>\n"
     62                    "Options:\n"
     63                    "  -h, --help       A short option summary\n"
     64                    "  -v, --version    Print version information and exit\n"
     65                    "No output is printed; the return code is 1 if the files differ.\n",
     66                    cmdname);
    6767        }
    6868
     
    7373{
    7474        errno_t rc = EOK;
    75         const char *fn[2] = {fn0, fn1};
    76         int fd[2] = {-1, -1};
     75        const char *fn[2] = { fn0, fn1 };
     76        int fd[2] = { -1, -1 };
    7777        char buffer[2][CMP_BUFLEN];
    7878        size_t offset[2];
    79         aoff64_t pos[2] = {};
     79        aoff64_t pos[2] = { };
    8080
    8181        for (int i = 0; i < 2; i++) {
     
    142142        if (argc - optind != 2) {
    143143                printf("%s - incorrect number of arguments. Try `%s --help'\n",
    144                         cmdname, cmdname);
     144                    cmdname, cmdname);
    145145                return CMD_FAILURE;
    146146        }
  • uspace/app/bdsh/test/toktest.c

    r76d0981d r3bacee1  
    4343
    4444/* Tokenize the input, asserts that number of tokens is okay. */
    45 static void prepare(const char *input, size_t expected_token_count) {
     45static void prepare(const char *input, size_t expected_token_count)
     46{
    4647        str_cpy(input_buffer, MAX_INPUT, input);
    4748
     
    6869PCUT_TEST_SUITE(tokenizer);
    6970
    70 PCUT_TEST_AFTER {
     71PCUT_TEST_AFTER
     72{
    7173        /* Destroy the tokenizer. */
    7274        tok_fini(&tokenizer);
     
    7476
    7577
    76 PCUT_TEST(empty_input) {
     78PCUT_TEST(empty_input)
     79{
    7780        prepare("", 0);
    7881}
    7982
    80 PCUT_TEST(only_spaces) {
     83PCUT_TEST(only_spaces)
     84{
    8185        prepare("   ", 1);
    8286
     
    8488}
    8589
    86 PCUT_TEST(two_text_tokens) {
     90PCUT_TEST(two_text_tokens)
     91{
    8792        prepare("alpha  bravo", 3);
    8893
Note: See TracChangeset for help on using the changeset viewer.