summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-08-26 12:35:01 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-08-26 12:43:59 +0100
commitcadac8400a018c8c566379f7767ea5edff78523d (patch)
treea0a52df4519388a10222629a9446fbc7861f7752 /sd
parent94a52f9ffafdf9c6e64ddf1a3587f21a272f2e62 (diff)
don't hang on unreachable record ends
Change-Id: I288f7ff0327831603eda6e827c8acbae678dfaff
Diffstat (limited to 'sd')
-rw-r--r--sd/qa/unit/data/ppt/pass/hang-1.pptbin0 -> 7680 bytes
-rw-r--r--sd/source/filter/ppt/pptin.cxx7
2 files changed, 6 insertions, 1 deletions
diff --git a/sd/qa/unit/data/ppt/pass/hang-1.ppt b/sd/qa/unit/data/ppt/pass/hang-1.ppt
new file mode 100644
index 000000000000..d30cb8472ee9
--- /dev/null
+++ b/sd/qa/unit/data/ppt/pass/hang-1.ppt
Binary files differ
diff --git a/sd/source/filter/ppt/pptin.cxx b/sd/source/filter/ppt/pptin.cxx
index af1588f6bcf7..5f92ae82aa10 100644
--- a/sd/source/filter/ppt/pptin.cxx
+++ b/sd/source/filter/ppt/pptin.cxx
@@ -821,7 +821,12 @@ bool ImplSdPPTImport::Import()
}
break;
}
- aHd.SeekToEndOfRecord( rStCtrl );
+ bool bSuccess = aHd.SeekToEndOfRecord(rStCtrl);
+ if (!bSuccess)
+ {
+ SAL_WARN("filter.ms", "Count not seek to end of record");
+ break;
+ }
}
}
rStCtrl.Seek( nFPosMerk );