aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorStefan Richter <stefanr@s5r6.in-berlin.de>2010-07-22 05:58:05 -0400
committerStefan Richter <stefanr@s5r6.in-berlin.de>2010-07-27 05:04:12 -0400
commita8461c0f3bfffe752fc62ce3960eb827463e90b5 (patch)
tree6f084345ddad45459397846a069dc5fde7a3b736 /tools
parent1bcc69fb6a48edb3ddf2e8c42f1d1c242196bf74 (diff)
tools/firewire: nosy-dump: work around segfault in decode_fcp
If I run "nosy-dump --view=transaction" with my camcorder on battery instead of mains, it segfaults very quickly because of !t->request. Perhaps this is because of increased likelyhood of incomplete transactions (ack_busy when host writes to camcorder's FCP_Request) and a bug deeper in nosy-dump's transaction housekeeping. This is a quick workaround to get me going. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'tools')
-rw-r--r--tools/firewire/nosy-dump.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tools/firewire/nosy-dump.c b/tools/firewire/nosy-dump.c
index 0bad0a42d772..1d4dd5439d43 100644
--- a/tools/firewire/nosy-dump.c
+++ b/tools/firewire/nosy-dump.c
@@ -230,6 +230,11 @@ handle_transaction(struct link_transaction *t)
230 struct subaction *sa; 230 struct subaction *sa;
231 int i; 231 int i;
232 232
233 if (!t->request) {
234 printf("BUG in handle_transaction\n");
235 return;
236 }
237
233 for (i = 0; i < array_length(protocol_decoders); i++) 238 for (i = 0; i < array_length(protocol_decoders); i++)
234 if (protocol_decoders[i].decode(t)) 239 if (protocol_decoders[i].decode(t))
235 break; 240 break;