Re: [PATCH] Do not automatically backtrace when telnetd quits (#588964).

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ack.

On 05/05/2010 04:59 PM, Chris Lumens wrote:
We were getting a backtrace because we were asking for it.  We have an atexit
handler that does a backtrace unless expected_exit is set.  doExit sets that
for us, so quit through doExit instead of regular exit.
---
  loader/loader.c  |    3 +--
  loader/loader.h  |    1 +
  loader/telnetd.c |    2 +-
  3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/loader/loader.c b/loader/loader.c
index df82c5b..a601f0f 100644
--- a/loader/loader.c
+++ b/loader/loader.c
@@ -137,8 +137,7 @@ static int numMethods = sizeof(installMethods) / sizeof(struct installMethod);

  static int expected_exit = 0;

-static void doExit(int) __attribute__ ((noreturn));
-static void doExit(int result)
+void doExit(int result)
  {
      expected_exit = 1;
      exit(result);
diff --git a/loader/loader.h b/loader/loader.h
index c88457f..c64c475 100644
--- a/loader/loader.h
+++ b/loader/loader.h
@@ -109,6 +109,7 @@
  #define FL_KICKSTART_SEND_SERIAL(a) ((a)&  LOADER_FLAGS_KICKSTART_SEND_SERIAL)
  #define FL_AUTOMODDISK(a)        ((a)&  LOADER_FLAGS_AUTOMODDISK)

+void doExit(int) __attribute__ ((noreturn));
  void startNewt(void);
  void stopNewt(void);
  char * getProductName(void);
diff --git a/loader/telnetd.c b/loader/telnetd.c
index cdf7e16..7616181 100644
--- a/loader/telnetd.c
+++ b/loader/telnetd.c
@@ -201,7 +201,7 @@ int beTelnet(void) {

          kill(child, SIGTERM);
          close(conn);
-        exit(0);
+        doExit(0);
      }

      unlockpt(masterFd);

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux