[X2Go-Commits] [pale-moon] 201/294: Unhook CR exception handler.

git-admin at x2go.org git-admin at x2go.org
Sat Apr 27 08:58:12 CEST 2019


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch upstream/28.5.0
in repository pale-moon.

commit bfc97728065cbbc7f6bbc281b654a2d1e079b48d
Author: wolfbeast <mcwerewolf at wolfbeast.com>
Date:   Mon Apr 1 13:04:33 2019 +0200

    Unhook CR exception handler.
    
    Tag #20
---
 gfx/ipc/GPUParent.cpp              |  1 -
 ipc/glue/GeckoChildProcessHost.cpp |  2 -
 toolkit/xre/nsAndroidStartup.cpp   |  1 -
 toolkit/xre/nsEmbedFunctions.cpp   |  1 -
 toolkit/xre/nsX11ErrorHandler.cpp  |  1 -
 xpcom/base/nsObjCExceptions.h      | 78 --------------------------------------
 6 files changed, 84 deletions(-)

diff --git a/gfx/ipc/GPUParent.cpp b/gfx/ipc/GPUParent.cpp
index 9ff6cba..6833f56 100644
--- a/gfx/ipc/GPUParent.cpp
+++ b/gfx/ipc/GPUParent.cpp
@@ -24,7 +24,6 @@
 #include "mozilla/dom/VideoDecoderManagerChild.h"
 #include "mozilla/layers/LayerTreeOwnerTracker.h"
 #include "nsDebugImpl.h"
-#include "nsExceptionHandler.h"
 #include "nsThreadManager.h"
 #include "prenv.h"
 #include "ProcessUtils.h"
diff --git a/ipc/glue/GeckoChildProcessHost.cpp b/ipc/glue/GeckoChildProcessHost.cpp
index 8147e87..fee4292 100644
--- a/ipc/glue/GeckoChildProcessHost.cpp
+++ b/ipc/glue/GeckoChildProcessHost.cpp
@@ -23,8 +23,6 @@
 #include "prenv.h"
 #include "nsXPCOMPrivate.h"
 
-#include "nsExceptionHandler.h"
-
 #include "nsDirectoryServiceDefs.h"
 #include "nsIFile.h"
 #include "nsPrintfCString.h"
diff --git a/toolkit/xre/nsAndroidStartup.cpp b/toolkit/xre/nsAndroidStartup.cpp
index 47b9ec6..68ad75c 100644
--- a/toolkit/xre/nsAndroidStartup.cpp
+++ b/toolkit/xre/nsAndroidStartup.cpp
@@ -17,7 +17,6 @@
 #include "nsIFile.h"
 #include "nsAppRunner.h"
 #include "APKOpen.h"
-#include "nsExceptionHandler.h"
 
 #define LOG(args...) __android_log_print(ANDROID_LOG_INFO, MOZ_APP_NAME, args)
 
diff --git a/toolkit/xre/nsEmbedFunctions.cpp b/toolkit/xre/nsEmbedFunctions.cpp
index 3757dec..52b4437 100644
--- a/toolkit/xre/nsEmbedFunctions.cpp
+++ b/toolkit/xre/nsEmbedFunctions.cpp
@@ -32,7 +32,6 @@
 #include "nsAppRunner.h"
 #include "nsAutoRef.h"
 #include "nsDirectoryServiceDefs.h"
-#include "nsExceptionHandler.h"
 #include "nsString.h"
 #include "nsThreadUtils.h"
 #include "nsJSUtils.h"
diff --git a/toolkit/xre/nsX11ErrorHandler.cpp b/toolkit/xre/nsX11ErrorHandler.cpp
index 0fb0d29..9a6888a 100644
--- a/toolkit/xre/nsX11ErrorHandler.cpp
+++ b/toolkit/xre/nsX11ErrorHandler.cpp
@@ -7,7 +7,6 @@
 
 #include "prenv.h"
 #include "nsXULAppAPI.h"
-#include "nsExceptionHandler.h"
 #include "nsDebug.h"
 
 #include "mozilla/X11Util.h"
diff --git a/xpcom/base/nsObjCExceptions.h b/xpcom/base/nsObjCExceptions.h
index b3ed532..e542a22 100644
--- a/xpcom/base/nsObjCExceptions.h
+++ b/xpcom/base/nsObjCExceptions.h
@@ -13,10 +13,6 @@
 
 #import <Foundation/Foundation.h>
 
-#ifdef DEBUG
-#import <ExceptionHandling/NSExceptionHandler.h>
-#endif
-
 #include <unistd.h>
 #include <signal.h>
 #include "nsError.h"
@@ -40,80 +36,6 @@ nsObjCExceptionLog(NSException* aException)
 {
   NSLog(@"Mozilla has caught an Obj-C exception [%@: %@]",
         [aException name], [aException reason]);
-
-#ifdef DEBUG
-  @try {
-    // Try to get stack information out of the exception. 10.5 returns the stack
-    // info with the callStackReturnAddresses selector.
-    NSArray* stackTrace = nil;
-    if ([aException respondsToSelector:@selector(callStackReturnAddresses)]) {
-      NSArray* addresses = (NSArray*)
-        [aException performSelector:@selector(callStackReturnAddresses)];
-      if ([addresses count]) {
-        stackTrace = addresses;
-      }
-    }
-
-    // 10.4 doesn't respond to callStackReturnAddresses so we'll try to pull the
-    // stack info out of the userInfo. It might not be there, sadly :(
-    if (!stackTrace) {
-      stackTrace = [[aException userInfo] objectForKey:NSStackTraceKey];
-    }
-
-    if (stackTrace) {
-      // The command line should look like this:
-      //   /usr/bin/atos -p <pid> -printHeader <stack frame addresses>
-      NSMutableArray* args =
-        [NSMutableArray arrayWithCapacity:[stackTrace count] + 3];
-
-      [args addObject:@"-p"];
-      int pid = [[NSProcessInfo processInfo] processIdentifier];
-      [args addObject:[NSString stringWithFormat:@"%d", pid]];
-
-      [args addObject:@"-printHeader"];
-
-      unsigned int stackCount = [stackTrace count];
-      unsigned int stackIndex = 0;
-      for (; stackIndex < stackCount; stackIndex++) {
-        unsigned long address =
-          [[stackTrace objectAtIndex:stackIndex] unsignedLongValue];
-        [args addObject:[NSString stringWithFormat:@"0x%lx", address]];
-      }
-
-      NSPipe* outPipe = [NSPipe pipe];
-
-      NSTask* task = [[NSTask alloc] init];
-      [task setLaunchPath:@"/usr/bin/atos"];
-      [task setArguments:args];
-      [task setStandardOutput:outPipe];
-      [task setStandardError:outPipe];
-
-      NSLog(@"Generating stack trace for Obj-C exception...");
-
-      // This will throw an exception if the atos tool cannot be found, and in
-      // that case we'll just hit our @catch block below.
-      [task launch];
-
-      [task waitUntilExit];
-      [task release];
-
-      NSData* outData =
-        [[outPipe fileHandleForReading] readDataToEndOfFile];
-      NSString* outString =
-        [[NSString alloc] initWithData:outData encoding:NSUTF8StringEncoding];
-
-      NSLog(@"Stack trace:\n%@", outString);
-
-      [outString release];
-    } else {
-      NSLog(@"<No stack information available for Obj-C exception>");
-    }
-  }
-  @catch (NSException* exn) {
-    NSLog(@"Failed to generate stack trace for Obj-C exception [%@: %@]",
-          [exn name], [exn reason]);
-  }
-#endif
 }
 
 __attribute__((unused))

--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pale-moon.git


More information about the x2go-commits mailing list