Changeset c47e1a8 in mainline for uspace/app/getterm/getterm.c


Ignore:
Timestamp:
2010-05-21T07:50:04Z (16 years ago)
Author:
Lenka Trochtova <trochtova.lenka@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
d51ee2b
Parents:
cf8cc36 (diff), 15b592b (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 (rev. 451)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/getterm/getterm.c

    rcf8cc36 rc47e1a8  
    4040#include <stdio.h>
    4141#include <task.h>
     42#include <str_error.h>
    4243#include "version.h"
     44
     45#define APP_NAME  "getterm"
    4346
    4447static void usage(void)
    4548{
    46         printf("Usage: getterm <terminal> <path>\n");
     49        printf("Usage: %s <terminal> <path>\n", APP_NAME);
    4750}
    4851
     
    6972}
    7073
    71 static task_id_t spawn(char *fname)
     74static task_id_t spawn(const char *fname)
    7275{
    73         char *args[2];
     76        const char *args[2];
    7477       
    7578        args[0] = fname;
    7679        args[1] = NULL;
    7780       
    78         task_id_t id = task_spawn(fname, args);
     81        int err;
     82        task_id_t id = task_spawn(fname, args, &err);
    7983       
    8084        if (id == 0)
    81                 printf("Error spawning %s\n", fname);
     85                printf("%s: Error spawning %s (%s)\n", APP_NAME, fname,
     86                    str_error(err));
    8287       
    8388        return id;
Note: See TracChangeset for help on using the changeset viewer.