Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mruby
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
mruby
Commits
7b04fcd0
Commit
7b04fcd0
authored
Sep 24, 2018
by
Clayton Smith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix comparisons in str_squeeze.
parent
8fc56f06
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
mrbgems/mruby-string-ext/src/string.c
mrbgems/mruby-string-ext/src/string.c
+2
-2
No files found.
mrbgems/mruby-string-ext/src/string.c
View file @
7b04fcd0
...
@@ -543,7 +543,7 @@ str_squeeze(mrb_state *mrb, mrb_value str, mrb_value v_pat)
...
@@ -543,7 +543,7 @@ str_squeeze(mrb_state *mrb, mrb_value str, mrb_value v_pat)
{
{
struct
tr_pattern
*
pat
=
NULL
;
struct
tr_pattern
*
pat
=
NULL
;
mrb_int
i
;
mrb_int
i
;
char
*
s
;
unsigned
char
*
s
;
mrb_int
len
;
mrb_int
len
;
mrb_bool
flag_changed
=
FALSE
;
mrb_bool
flag_changed
=
FALSE
;
mrb_int
lastch
=
-
1
;
mrb_int
lastch
=
-
1
;
...
@@ -552,7 +552,7 @@ str_squeeze(mrb_state *mrb, mrb_value str, mrb_value v_pat)
...
@@ -552,7 +552,7 @@ str_squeeze(mrb_state *mrb, mrb_value str, mrb_value v_pat)
if
(
!
mrb_nil_p
(
v_pat
))
{
if
(
!
mrb_nil_p
(
v_pat
))
{
pat
=
tr_parse_pattern
(
mrb
,
pat
,
v_pat
,
TRUE
);
pat
=
tr_parse_pattern
(
mrb
,
pat
,
v_pat
,
TRUE
);
}
}
s
=
RSTRING_PTR
(
str
);
s
=
(
unsigned
char
*
)
RSTRING_PTR
(
str
);
len
=
RSTRING_LEN
(
str
);
len
=
RSTRING_LEN
(
str
);
if
(
pat
)
{
if
(
pat
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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