Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Kate
Commits
a5a57375
Commit
a5a57375
authored
Jul 09, 2011
by
Dominik Haumann
Browse files
fix crash due to out-of-range index access
BUG: 277385
parent
6ccfe6bc
Changes
1
Hide whitespace changes
Inline
Side-by-side
playground/kte_acomment/artisticcomment.cpp
View file @
a5a57375
...
...
@@ -31,8 +31,10 @@ static QList<QString> explode(QString str, size_t max)
QList
<
QString
>
ret
;
QString
curr
;
QString
currWord
;
if
(
str
[
str
.
size
()
-
1
]
!=
'\n'
)
if
(
str
.
size
()
>
0
&&
!
str
.
endsWith
(
'\n'
)
)
{
str
+=
'\n'
;
}
for
(
int
i
=
0
;
i
!=
str
.
size
();
++
i
)
{
if
(
str
[
i
]
==
'\n'
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment