mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-18 14:38:04 -06:00
- BUGFIX: Stop catching signals once one has been caught to avoid possible infinite loop
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
* Unreleased - Christophe Dumez <chris@qbittorrent.org> - v2.0.6
|
||||
- BUGFIX: Fix detection of invalid torrent files
|
||||
- BUGFIX: Stop catching signals once one has been caught to avoid possible infinite loop
|
||||
|
||||
* Web Dec 31 2009 - Christophe Dumez <chris@qbittorrent.org> - v2.0.5
|
||||
- BUGFIX: Fix crash with downloaded/availability bars when the torrent has too many pieces
|
||||
|
||||
@@ -62,10 +62,13 @@ QApplication *app;
|
||||
|
||||
#ifndef Q_WS_WIN
|
||||
void sigtermHandler(int) {
|
||||
signal(SIGTERM, 0);
|
||||
qDebug("Catching SIGTERM, exiting cleanly");
|
||||
app->exit();
|
||||
}
|
||||
void sigsegvHandler(int) {
|
||||
signal(SIGABRT, 0);
|
||||
signal(SIGSEGV, 0);
|
||||
std::cerr << "\n\n*************************************************************\n";
|
||||
std::cerr << "Catching SIGSEGV, please report a bug at http://bug.qbittorrent.org\nand provide the following backtrace:\n";
|
||||
print_stacktrace();
|
||||
@@ -73,6 +76,8 @@ void sigsegvHandler(int) {
|
||||
std::abort();
|
||||
}
|
||||
void sigabrtHandler(int) {
|
||||
signal(SIGABRT, 0);
|
||||
signal(SIGSEGV, 0);
|
||||
std::cerr << "\n\n*************************************************************\n";
|
||||
std::cerr << "Catching SIGABRT, please report a bug at http://bug.qbittorrent.org\nand provide the following backtrace:\n";
|
||||
print_stacktrace();
|
||||
@@ -210,6 +215,7 @@ int main(int argc, char *argv[]){
|
||||
delete splash;
|
||||
}
|
||||
int ret = app->exec();
|
||||
signal(SIGTERM, 0);
|
||||
delete window;
|
||||
qDebug("GUI was deleted!");
|
||||
qDebug("Deleting app...");
|
||||
|
||||
Reference in New Issue
Block a user