Remove logging to error output 47/206647/3
authorMateusz Moscicki <m.moscicki2@partner.samsung.com>
Wed, 22 May 2019 10:37:09 +0000 (12:37 +0200)
committerMateusz Moscicki <m.moscicki2@partner.samsung.com>
Tue, 28 May 2019 12:16:40 +0000 (14:16 +0200)
Change-Id: I7abce9958153729ed7ae91d582970211ad0e004f

src/crash-stack/crash-stack.c

index fc97c0c..c0f9604 100644 (file)
@@ -67,7 +67,6 @@
 #define STRWW_FS(macro) STRINGWW_FORMAT_SPECIFIER_WITH_MACRO(macro)
 
 static FILE *outputfile = NULL;                ///< global output stream
-static FILE *errfile = NULL;           ///< global error stream
 static FILE *bufferfile = NULL;                ///< buffer file for ordering
 
 /**
@@ -78,7 +77,6 @@ enum {
        OPT_TID,
        OPT_SIGNUM,
        OPT_OUTPUTFILE,
-       OPT_ERRFILE,
        OPT_PRSTATUS_FD
 };
 
@@ -90,7 +88,6 @@ const struct option opts[] = {
        { "tid", required_argument, 0, OPT_TID },
        { "sig", required_argument, 0, OPT_SIGNUM },
        { "output", required_argument, 0, OPT_OUTPUTFILE },
-       { "erroutput", required_argument, 0, OPT_ERRFILE },
        { "prstatus_fd", required_argument, 0, OPT_PRSTATUS_FD },
        { 0, 0, 0, 0 }
 };
@@ -615,10 +612,6 @@ int main(int argc, char **argv)
                case OPT_OUTPUTFILE:
                        outputfile = fopen(optarg, "w");
                        break;
-               case OPT_ERRFILE:
-                       errfile = fopen(optarg, "w");
-                       _W("--erroutput is deprecated");
-                       break;
                case OPT_PRSTATUS_FD:
                        prstatus_fd = strtol(optarg, &p, 10);
                        if (*p != 0)
@@ -627,11 +620,10 @@ int main(int argc, char **argv)
                }
        }
 
-       if (NULL == errfile) errfile = stderr;
        if (NULL == outputfile) outputfile = stdout;
 
        if (tid == 0) {
-               fprintf(errfile, "TID not provided\n");
+               _E("TID not provided");
                return errno;
        }