[Libreoffice-bugs] [Bug 131273] Crash when pasting quotes with fixed width
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Thu Mar 12 08:22:52 UTC 2020
https://bugs.documentfoundation.org/show_bug.cgi?id=131273
Samuel Mehrbrodt (CIB) <s.mehrbrodt at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|libreoffice-bugs at lists.free |serval2412 at yahoo.fr
|desktop.org |
--- Comment #4 from Samuel Mehrbrodt (CIB) <s.mehrbrodt at gmail.com> ---
(In reply to Julien Nabet from comment #3)
> Don't know if it's a naive patch but I don't reproduce the crash with it:
> diff --git a/sc/source/ui/docshell/impex.cxx
> b/sc/source/ui/docshell/impex.cxx
> index f99a8ce5fff5..56aa2e7f2506 100644
> --- a/sc/source/ui/docshell/impex.cxx
> +++ b/sc/source/ui/docshell/impex.cxx
> @@ -1278,7 +1278,7 @@ static OUString lcl_GetFixed( const OUString& rLine,
> sal_Int32 nStart, sal_Int32
> bool bFits = (nSpace - nStart - 3 <= SAL_MAX_UINT16);
> OSL_ENSURE( bFits, "lcl_GetFixed: line doesn't fit into data");
> if (bFits)
> - return rLine.copy(nStart+1, nSpace-nStart-2);
> + return rLine.copy(nStart+1, std::max(0, nSpace-nStart-2));
> else
> {
> rbOverflowCell = true;
Just upload to gerrit. Thx!
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20200312/67cc7caf/attachment-0001.htm>
More information about the Libreoffice-bugs
mailing list