mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
cleanup: remove SEARCH_TYPE from search_pattern_in_file.inc
This commit is contained in:
@ -9,9 +9,6 @@
|
||||
#
|
||||
# The environment variables SEARCH_FILE and SEARCH_PATTERN must be set
|
||||
# before sourcing this routine.
|
||||
# SEARCH_TYPE can also be set to either NULL(default) or _gm_
|
||||
# NULL is equivalent of using m/SEARCH_PATTERN/gs
|
||||
# _gm_ is equivalent of using m/SEARCH_RANGE/gm
|
||||
#
|
||||
# Optionally, SEARCH_RANGE can be set to the max number of bytes of the file
|
||||
# to search. If negative, it will search that many bytes at the end of the
|
||||
@ -83,15 +80,7 @@ perl;
|
||||
close(FILE);
|
||||
$content.= $file_content;
|
||||
}
|
||||
my @matches;
|
||||
if (not defined($ENV{SEARCH_TYPE}))
|
||||
{
|
||||
@matches=($content =~ /$search_pattern/gs);
|
||||
}
|
||||
elsif($ENV{SEARCH_TYPE} == "_gm_")
|
||||
{
|
||||
@matches=($content =~ /$search_pattern/gm);
|
||||
}
|
||||
my @matches= ($content =~ /$search_pattern/gs);
|
||||
my $res;
|
||||
if (@matches)
|
||||
{
|
||||
|
Reference in New Issue
Block a user