Control: tags -1 +pending Hi! While this bug has been RC for only two days, and it was me who bumped it, thus too much haste towards a NMU is inappropriate, we're very late in the freeze. Thus, I'm uploading a revert+Frédéric's patch to DELAYED/5.
Navigating through the editor via the pad and using Start for Enter just to make sure it actually works. :) Debdiff attached. Best way to ACK would be "dcut reschedule", best NAK "dcut cancel" or an immediate upload, but if anything is amiss, please holler. Meow! -- Don't be racist. White, amber or black, all beers should be judged based solely on their merits. Heck, even if occasionally a cider applies for a beer's job, why not? On the other hand, corpo lager is not a race.
diff -Nru qjoypad-4.1.0/debian/changelog qjoypad-4.1.0/debian/changelog --- qjoypad-4.1.0/debian/changelog 2016-10-18 08:50:02.000000000 +0200 +++ qjoypad-4.1.0/debian/changelog 2017-05-15 22:16:08.000000000 +0200 @@ -1,3 +1,10 @@ +qjoypad (4.1.0-2.1) unstable; urgency=medium + + * Non-maintainer upload. + * Use proper RAII to fix crash (Closes: #853801), thanks Frédéric Brière. + + -- Adam Borowski <kilob...@angband.pl> Mon, 15 May 2017 22:16:08 +0200 + qjoypad (4.1.0-2) unstable; urgency=medium * Team upload. diff -Nru qjoypad-4.1.0/debian/patches/fix_ftbfs_clang.patch qjoypad-4.1.0/debian/patches/fix_ftbfs_clang.patch --- qjoypad-4.1.0/debian/patches/fix_ftbfs_clang.patch 2016-10-12 08:56:25.000000000 +0200 +++ qjoypad-4.1.0/debian/patches/fix_ftbfs_clang.patch 1970-01-01 01:00:00.000000000 +0100 @@ -1,22 +0,0 @@ -# From: Alexander Ovchinnikov <sanek23...@gmail.com> -# Subject: Fix compile issues using clang ---- a/src/layout_edit.cpp -+++ b/src/layout_edit.cpp -@@ -39,7 +39,7 @@ - //this is only necesary since joystick devices need not always be - //contiguous - int padcount = available.count(); -- QString names[padcount]; -+ QString *names = static_cast<QString *>(alloca(sizeof(QString) * padcount)); - int i = 0; - do - { -@@ -119,7 +119,7 @@ - int indexOfFlashRadio = LMain->indexOf(JoyButtons); - FlashRadioArray *newJoyButtons; - int padcount = available.count(); -- QString names[padcount]; -+ QString *names = static_cast<QString *>(alloca(sizeof(QString) * padcount)); - int i = 0; - do - { diff -Nru qjoypad-4.1.0/debian/patches/properly-fix-752125.patch qjoypad-4.1.0/debian/patches/properly-fix-752125.patch --- qjoypad-4.1.0/debian/patches/properly-fix-752125.patch 1970-01-01 01:00:00.000000000 +0100 +++ qjoypad-4.1.0/debian/patches/properly-fix-752125.patch 2017-05-15 21:25:47.000000000 +0200 @@ -0,0 +1,58 @@ +From 96c9052c9d2033320019947035dcd3869b076f3f Mon Sep 17 00:00:00 2001 +From: Frédéric Brière <fbri...@fbriere.net> +Date: Fri, 17 Mar 2017 15:32:15 -0400 +Subject: [PATCH] Properly fix #752125 (closes #853801) + +--- + src/layout_edit.cpp | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) + +diff --git a/src/layout_edit.cpp b/src/layout_edit.cpp +index 8365104..5703ee3 100644 +--- a/src/layout_edit.cpp ++++ b/src/layout_edit.cpp +@@ -1,4 +1,5 @@ + #include "layout_edit.h" ++#include <vector> + + //build the dialog + LayoutEdit::LayoutEdit( LayoutManager* l ): QWidget(NULL) { +@@ -39,7 +40,7 @@ LayoutEdit::LayoutEdit( LayoutManager* l ): QWidget(NULL) { + //this is only necesary since joystick devices need not always be + //contiguous + int padcount = available.count(); +- QString names[padcount]; ++ std::vector<QString> names(padcount); + int i = 0; + do + { +@@ -54,7 +55,7 @@ LayoutEdit::LayoutEdit( LayoutManager* l ): QWidget(NULL) { + } while (0); + + //flash radio array +- JoyButtons = new FlashRadioArray(padcount, names, true, this ); ++ JoyButtons = new FlashRadioArray(padcount, &names[0], true, this ); + LMain->addWidget( JoyButtons ); + + //we have a WidgetStack to represent the multiple joypads +@@ -119,7 +120,7 @@ void LayoutEdit::updateJoypadWidgets() { + int indexOfFlashRadio = LMain->indexOf(JoyButtons); + FlashRadioArray *newJoyButtons; + int padcount = available.count(); +- QString names[padcount]; ++ std::vector<QString> names(padcount); + int i = 0; + do + { +@@ -132,7 +133,7 @@ void LayoutEdit::updateJoypadWidgets() { + } + } while (0); + +- newJoyButtons = new FlashRadioArray(padcount, names, true, this ); ++ newJoyButtons = new FlashRadioArray(padcount, &names[0], true, this ); + LMain->insertWidget(indexOfFlashRadio, newJoyButtons); + LMain->removeWidget(JoyButtons); + FlashRadioArray* oldJoyButtons = JoyButtons; +-- +2.11.0 + diff -Nru qjoypad-4.1.0/debian/patches/series qjoypad-4.1.0/debian/patches/series --- qjoypad-4.1.0/debian/patches/series 2016-10-12 08:56:25.000000000 +0200 +++ qjoypad-4.1.0/debian/patches/series 2017-05-15 21:19:05.000000000 +0200 @@ -1,2 +1,2 @@ -fix_ftbfs_clang.patch build_prefix.patch +properly-fix-752125.patch