Issue 8166 - Open Office crashes when a very long string is inserted into text field of" Line numbering"
Summary: Open Office crashes when a very long string is inserted into text field of" L...
Status: CLOSED FIXED
Alias: None
Product: Writer
Classification: Application
Component: code (show other issues)
Version: OOo 1.0.1
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: oc
QA Contact: issues@sw
URL:
Keywords: oooqa
Depends on:
Blocks:
 
Reported: 2002-10-09 05:15 UTC by sujit
Modified: 2013-08-07 14:43 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Cut and paste this entire file into the text field of the dialog box (98.62 KB, application/octet-stream)
2002-10-27 14:08 UTC, prgmgr
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description sujit 2002-10-09 05:15:03 UTC
The text field of "Line Numbering" accepts long strings which has caused this 
failure.

Steps to replicate bug

1.	Go to menu option Tools -> Line Numbering

2.	Check Show Numbering box

3.	Leave other fields on the Line Numbering dialog box to default value, 

4.	Input a text string from a file which is about 1 Mb, in the text field.

5.	Type a few lines of text to form a paragraph 


This appears to be a very important bug to fix. There should be some 
limitation in the length of the string accepted by the text field.

The application should have some kind of failsafe mechanism for extreme cases 
like this one, where the user can make the program crash. An example of such a 
mechanism would be to limit the size of the string that can be handled by the 
program. It could pop up an error message when the user tries to input a 
string that it cannot handle safely and notify the user that the string that 
is being used is too long to be considered safe.
Comment 1 prgmgr 2002-10-27 14:05:50 UTC
Sujit, thank you for using and supporting OOo.

For future reference, please attach a test file to reproduce your 
problem.  It helps us save time looking for a suitable test file that 
matches your criteria.  In this case, it would advisable to first 
compress ( zip, bzip, gzip ) the file first because of the size.

In summary, the term for these types of checks is called "bounds 
checking".  It's a hot topic these days.



Duplicated on Win NT 4.0 SP6a, OOo 643.

OOo hangs when inserting large amounts of text into the text 
separator field of the Line Numbering dialog box.
Comment 2 prgmgr 2002-10-27 14:08:02 UTC
Created attachment 3364 [details]
Cut and paste this entire file into the text field of the dialog box
Comment 3 prgmgr 2002-10-27 14:08:32 UTC
Reassigned to a starting contact point.
Comment 4 stefan.baltzer 2002-11-26 16:55:10 UTC
Reassigned to HI.
Comment 5 h.ilter 2002-11-28 11:08:49 UTC
HI->FL: A case for user experience.
Comment 6 frank.loehmann 2002-11-29 09:11:08 UTC
FL->OS: Please limit maximum string length of input field according 
to maximum of data type behind this field. Thank you!
Comment 7 Oliver Specht 2003-01-22 15:37:58 UTC
Target milestone set.
Comment 8 Oliver Specht 2003-01-28 09:39:25 UTC
OS->SB: There's an rtl::OUString longer than xub_StrLen converted into
a UniString with an invalid length. 

String::EraseAllChars(unsigned short 0x000a) line 1152
VCL644MI! Edit::ImplGetValidString(class String const &) + 66 bytes
VCL644MI! Edit::ImplInsertText(class String const &,class Selection
const *) + 93 bytes
VCL644MI! Edit::ReplaceSelected(class String const &) + 53 bytes
VCL644MI! Edit::ImplPaste(class com::sun::star::uno::Reference<class
com::sun::star::datatransfer::clipboard::XClipboard> &) + 491 bytes
int,long) + 38 bytes
USER32! 77d43a68()
Comment 9 Stephan Bergmann 2003-01-28 14:33:23 UTC
Looking for best solution.
Comment 10 malte_timmermann 2003-02-03 16:47:22 UTC
*** Issue 2056 has been marked as a duplicate of this issue. ***
Comment 11 malte_timmermann 2003-02-03 16:59:48 UTC
*** Issue 9771 has been marked as a duplicate of this issue. ***
Comment 12 Stephan Bergmann 2003-02-04 10:59:48 UTC
Fixed on SRX644 CWS rtlmath.
Comment 13 ooo 2003-02-05 13:03:15 UTC
reopen to reassign
Comment 14 ooo 2003-02-05 13:04:24 UTC
I said reopen ...
Comment 15 ooo 2003-02-05 13:06:15 UTC
reassign to QA
Comment 16 ooo 2003-02-05 13:06:42 UTC
restore status
Comment 17 eric.savary 2003-02-05 15:49:54 UTC
Added myself on CC to close issue 9771 when this one will be closed.
Comment 18 eric.savary 2003-02-10 10:03:49 UTC
verified
Comment 19 michael.bemmer 2003-03-13 11:09:36 UTC
As mentioned on the qa dev list on March 5th I will close all resolved
<wontfix/duplicate/worksforme/invalid> issues. Please see this posting for details.