merged fix from RC_0_16

This commit is contained in:
Arvid Norberg 2012-06-05 05:55:40 +00:00
parent 2be5513be7
commit 42a5185f24
3 changed files with 14 additions and 1 deletions

View File

@ -99,7 +99,7 @@ nobase_include_HEADERS = \
stat.hpp \
storage.hpp \
storage_defs.hpp \
sruct_debug.hpp \
struct_debug.hpp \
thread.hpp \
time.hpp \
timestamp_history.hpp \

View File

@ -16,12 +16,15 @@ test_programs = \
test_pex \
test_piece_picker \
test_primitives \
test_rss \
test_storage \
test_swarm \
test_threads \
test_torrent \
test_trackers_extension \
test_transfer \
test_upnp \
test_utp \
test_web_seed
if ENABLE_TESTS
@ -57,10 +60,13 @@ test_piece_picker_SOURCES = test_piece_picker.cpp
test_primitives_SOURCES = test_primitives.cpp
test_storage_SOURCES = test_storage.cpp
test_swarm_SOURCES = test_swarm.cpp
test_rss_SOURCES = test_rss.cpp
test_threads_SOURCES = test_threads.cpp
test_torrent_SOURCES = test_torrent.cpp
test_trackers_extension_SOURCES = test_trackers_extension.cpp
test_transfer_SOURCES = test_transfer.cpp
test_upnp_SOURCES = test_upnp.cpp
test_utp_SOURCES = test_utp.cpp
test_web_seed_SOURCES = test_web_seed.cpp
LDADD = $(top_builddir)/src/libtorrent-rasterbar.la libtest.la

View File

@ -45,7 +45,14 @@ extern bool tests_failure;
void sig_handler(int sig)
{
char stack_text[10000];
#if defined TORRENT_DEBUG || TORRENT_RELEASE_ASSERTS
print_backtrace(stack_text, sizeof(stack_text), 30);
#elif defined __FUNCTION__
strcat(stack_text, __FUNCTION__);
#else
stack_text[0] = 0;
#endif
char const* sig_name = 0;
switch (sig)
{