mirror of
https://github.com/lubosz/overte.git
synced 2025-04-24 09:43:25 +02:00
Merge pull request #258 from birarda/stacktraces
remove the current un-helpful stacktrace setup
This commit is contained in:
commit
983964f5bf
3 changed files with 1 additions and 47 deletions
|
@ -22,7 +22,6 @@
|
|||
#include <AgentTypes.h>
|
||||
#include <SharedUtil.h>
|
||||
#include <StdDev.h>
|
||||
#include <Stacktrace.h>
|
||||
|
||||
#include "AudioRingBuffer.h"
|
||||
#include "PacketHeaders.h"
|
||||
|
@ -258,8 +257,7 @@ void attachNewBufferToAgent(Agent *newAgent) {
|
|||
}
|
||||
}
|
||||
|
||||
int main(int argc, const char* argv[]) {
|
||||
signal(SIGSEGV, printStacktrace);
|
||||
int main(int argc, const char* argv[]) {
|
||||
setvbuf(stdout, NULL, _IOLBF, 0);
|
||||
|
||||
AgentList* agentList = AgentList::createInstance(AGENT_TYPE_AUDIO_MIXER, MIXER_LISTEN_PORT);
|
||||
|
|
|
@ -1,28 +0,0 @@
|
|||
//
|
||||
// Stacktrace.cpp
|
||||
// hifi
|
||||
//
|
||||
// Created by Stephen Birarda on 5/6/13.
|
||||
//
|
||||
//
|
||||
|
||||
#include <signal.h>
|
||||
#include <stdio.h>
|
||||
#include <execinfo.h>
|
||||
#include <cstdlib>
|
||||
|
||||
#include "Stacktrace.h"
|
||||
|
||||
const int NUMBER_OF_STACK_ENTRIES = 20;
|
||||
|
||||
void printStacktrace(int signal) {
|
||||
void* array[NUMBER_OF_STACK_ENTRIES];
|
||||
|
||||
// get void*'s for all entries on the stack
|
||||
size_t size = backtrace(array, NUMBER_OF_STACK_ENTRIES);
|
||||
|
||||
// print out all the frames to stderr
|
||||
fprintf(stderr, "Error: signal %d:\n", signal);
|
||||
backtrace_symbols_fd(array, size, 2);
|
||||
exit(1);
|
||||
}
|
|
@ -1,16 +0,0 @@
|
|||
//
|
||||
// Stacktrace.h
|
||||
// hifi
|
||||
//
|
||||
// Created by Stephen Birarda on 5/6/13.
|
||||
//
|
||||
//
|
||||
|
||||
#ifndef __hifi__Stacktrace__
|
||||
#define __hifi__Stacktrace__
|
||||
|
||||
#include <iostream>
|
||||
|
||||
void printStacktrace(int signal);
|
||||
|
||||
#endif /* defined(__hifi__Stacktrace__) */
|
Loading…
Reference in a new issue