<p dir="ltr">This seems... Unlikely?<br>
If the model row is < than the <a href="http://pinfo.nr">pinfo.nr</a>, things should always point to a safe memory zone. </p>
<div class="gmail_quote">Em 15 de jan de 2016 11:05, "Dirk Hohndel" <<a href="mailto:dirk@hohndel.org">dirk@hohndel.org</a>> escreveu:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Fri, Jan 15, 2016 at 12:22:30PM +0200, Miika Turkia wrote:<br>
><br>
> Well, it seems that the libs on the debug apk are stripped, so I fail<br>
> to get more exact information out of this (first time trying to dig<br>
> into tombstone, so that might affect the results as well). Anyway,<br>
> hopefully the following back trace will give others some more info on<br>
> the crash. At least the functions in question can be seen.<br>
> ---8<---<br>
> ********** Crash dump: **********<br>
> Build fingerprint:<br>
> 'Wileyfox/Swift/crackling:5.1.1/LMY49F/877353b5ea:userdebug/test-keys'<br>
> pid: 6293, tid: 6319, name: QtThread  >>> org.subsurfacedivelog.mobile <<<<br>
> signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0xf035f188<br>
> Stack frame #00 pc 0000fadc  /system/lib/libc.so (memcpy+96)<br>
> Stack frame #01 pc 000e730f<br>
> /data/app/org.subsurfacedivelog.mobile-2/lib/arm/libsubsurface-mobile.so<br>
> (DivePlotDataModel::data(QModelIndex const&, int) const+54)<br>
> Stack frame #02 pc 000d6275<br>
> /data/app/org.subsurfacedivelog.mobile-2/lib/arm/libsubsurface-mobile.so<br>
> (DiveProfileItem::paint(QPainter*, QStyleOptionGraphicsItem const*,<br>
> QWidget*)+336)<br>
> Stack frame #03 pc 00235d53<br>
<br>
Yes, I was able to reproduce this (with some effort) on a desktop system,<br>
but only if NOT running under a debugger. Nice. What is happening is that<br>
in diveplotdatamodel.cpp we do this<br>
<br>
QVariant DivePlotDataModel::data(const QModelIndex &index, int role) const<br>
{<br>
        if ((!index.isValid()) || (index.row() >= pInfo.nr))<br>
                return QVariant();<br>
<br>
        plot_data item = pInfo.entry[index.row()];<br>
<br>
And that copy operation above causes memcpy to crash.<br>
<br>
What I haven't quite figured out, yet, is why...<br>
<br>
/D<br>
_______________________________________________<br>
subsurface mailing list<br>
<a href="mailto:subsurface@subsurface-divelog.org">subsurface@subsurface-divelog.org</a><br>
<a href="http://lists.subsurface-divelog.org/cgi-bin/mailman/listinfo/subsurface" rel="noreferrer" target="_blank">http://lists.subsurface-divelog.org/cgi-bin/mailman/listinfo/subsurface</a><br>
</blockquote></div>