Bug 82143 - css crash in blank page adding a dot
Summary: css crash in blank page adding a dot
Status: RESOLVED FIXED
Alias: None
Product: quanta
Classification: Unmaintained
Component: general (show other bugs)
Version: unspecified
Platform: Mandrake RPMs Linux
: NOR crash
Target Milestone: ---
Assignee: András Manţia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-05-25 09:57 UTC by Rafael Matito
Modified: 2004-05-25 21:20 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rafael Matito 2004-05-25 09:57:34 UTC
Version:           3.3 BE2 (using KDE KDE 3.2.2)
Installed from:    Mandrake RPMs
Compiler:          gcc 3.3 
OS:                Linux

(Sorry for my bad english)

In a css page I delete all the text in the page and type a dot, then quanta crash.
Comment 1 András Manţia 2004-05-25 21:20:44 UTC
CVS commit by amantia: 

Don't crash when inserting a dot in an empty CSS file 

CCMAIL: 82143-done@bugs.kde.org


  M +1 -0      ChangeLog   1.286
  M +2 -2      parsers/saparser.cpp   1.44


--- kdewebdev/quanta/ChangeLog  #1.285:1.286
@@ -24,4 +24,5 @@
            context menu
         - unconditionally hide the splash screen after 10 seconds [#80086, #82013]
+        - don't crash when inserting a dot in an empty CSS file [#82143]
 
   - behavioral/user interface changes:

--- kdewebdev/quanta/parsers/saparser.cpp  #1.43:1.44
@@ -746,5 +746,5 @@ Node *SAParser::parsingDone()
     {
       n = s_currentNode;
-      while (n->prev)
+      while (n && n->prev)
         n = n->prev;
       s_currentNode = n;
@@ -771,5 +771,5 @@ Node *SAParser::parsingDone()
   if (s_fullParse && m_currentNode)
   {
-      if (m_useNext)
+      if (m_useNext && s_currentNode)
       {
         Node *n = s_currentNode;