Merge lp:~ev/apport/1205608 into lp:apport

Proposed by Evan
Status: Rejected
Rejected by: Martin Pitt
Proposed branch: lp:~ev/apport/1205608
Merge into: lp:apport
Diff against target: 26 lines (+3/-2)
2 files modified
NEWS (+1/-0)
bin/apport-retrace (+2/-2)
To merge this branch: bzr merge lp:~ev/apport/1205608
Reviewer Review Type Date Requested Status
Martin Pitt (community) Disapprove
Review via email:

Description of the change

Fixes a crash when you specify a sandbox but not a cache.

To post a comment you must log in.
Martin Pitt (pitti) wrote :

Just a quick review, I'm on my way out.

We create a temporary cache if the user doesn't specify one, so we should rather fix the logic to use that then. It shouldn't be mandatory to use a permanent cache; in fact it's quite redundant with doing stuff on /tmp/ on a tmpfs and having apt-cacher-ng (I have that).

review: Needs Fixing
Martin Pitt (pitti) wrote :

Please note that in the report the user didn't actually use a sandbox. His command (apport-retrace -s xxx.crash) works fine on current trunk now. I can reproduce the crash with -S without -C, but that has a simple fix. So I'm closing this MP.

Thanks anyway!

review: Disapprove
Evan (ev) wrote :

Ah, apologies for that!

Unmerged revisions

2669. By Evan on 2013-07-29

* apport-retrace: disallow using a sandbox without a cache (LP: #1205608).

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'NEWS'
2--- NEWS 2013-07-23 04:58:15 +0000
3+++ NEWS 2013-07-29 15:51:29 +0000
4@@ -13,6 +13,7 @@
5 together, and give a proper error message in this case. (LP: #1071905)
6 * apport: Fix "Exectuable" typo, leading to reports not being synced on
7 upstart crashes. Thanks James Hunt. (LP: #1203744)
8+ * apport-retrace: disallow using a sandbox without a cache (LP: #1205608).
10 2.11 (2013-07-17)
11 -----------------
13=== modified file 'bin/apport-retrace'
14--- bin/apport-retrace 2013-01-07 20:39:20 +0000
15+++ bin/apport-retrace 2013-07-29 15:51:29 +0000
16@@ -72,8 +72,8 @@
18 # catch invalid usage of -C without -S (cache is only used when making a
19 # sandbox)
20- if opts.cache and not opts.sandbox:
21- optparser.error(_('You cannot use -C without -S. Stopping.'))
22+ if (opts.cache and not opts.sandbox) or (opts.sandbox and not opts.cache):
23+ optparser.error(_('You cannot use -C without -S or vice versa. Stopping.'))
24 sys.exit(1)
26 if not (opts.auth or opts.output or opts.stdout or opts.gdb):


People subscribed via source and target branches