[sw-issues] [Issue 92736] Crash in hunspell with Win dows non-pro versions

2008-08-15 Thread nemeth
To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=92736


User nemeth changed the following:

What|Old value |New value

   Component|Word processor|lingucomponent

  Status|NEW   |RESOLVED

  QA contact|[EMAIL PROTECTED] |[EMAIL PROTECTED]

  Resolution|  |FIXED

Subcomponent|code  |spell checking





--- Additional comments from [EMAIL PROTECTED] Fri Aug 15 12:38:59 + 
2008 ---
Fixed in Hunspell 1.2.7. Thanks for the report, László

-
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[sw-issues] [Issue 92736] Crash in hunspell with Win dows non-pro versions

2008-08-13 Thread tl
To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=92736


User tl changed the following:

What|Old value |New value

 Assigned to|tl|nemeth

Priority|P3|P2

Target milestone|---   |OOo 3.0.1





--- Additional comments from [EMAIL PROTECTED] Wed Aug 13 08:13:13 + 
2008 ---
.

-
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[sw-issues] [Issue 92736] Crash in hunspell with Win dows non-pro versions

2008-08-13 Thread tl
To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=92736
 Issue #|92736
 Summary|Crash in hunspell with Windows non-pro versions
   Component|Word processor
 Version|DEV300m26
Platform|All
 URL|
  OS/Version|All
  Status|NEW
   Status whiteboard|
Keywords|
  Resolution|
  Issue type|DEFECT
Priority|P3
Subcomponent|code
 Assigned to|tl
 Reported by|tl





--- Additional comments from [EMAIL PROTECTED] Wed Aug 13 08:12:34 + 
2008 ---
In hunspells code (at least in phonet.c) there are calls like
  isalpha(word[i+k])
and
  isdigit (*s)

Which may cause the program to crash with in Windows C runtime library because
of running into assertions.

The problem is the usage of function like
  int isalnum(int c);
   int isalpha(int c);
   int isascii(int c);
   int isblank(int c);
   int iscntrl(int c);
   int isdigit(int c);
   int isgraph(int c);
   int islower(int c);
   int isprint(int c);
   int ispunct(int c);
   int isspace(int c);
   int isupper(int c);
   int isxdigit(int c);
Which are declared to take a (signed) int as parameter.
When those function are called for 'char' type paramters like
const char * s;
char word[MAXPHONETUTF8LEN + 1];
in phonet.c and they hold values from the higher half of the code page (chars
>127) e.g. for accented characters or German Umlaute those are represented as
signed chars and thus there value is negative (e.g. such as -55) when that value
is handed over as int parameter sign propagation comes into effect and the
resulting in will still be negative (-55). But interpreted as unsigned int it's
value is higher than 256 and the Windows runtime assertion will cause the
program to crash.

Solution:
When calling the above listed function all arguments must be converted to
unsigned character first before calling them!
That is the code needs to looks like
  isalpha((unsigned char) word[i+k])
and
  isdigit ((unsigned char) *s)

You Probably like to introduce an inline functions like
int MyIsAlpha(char c)
{
  return isalpha((unsigned char) c)
}
for better handling of this problem...

-
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]