Skip to content

Commit 07bb2c6

Browse files
Replace eregi() occurrences by insensitive preg_match() (#94)
1 parent fcb83b7 commit 07bb2c6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

scripts/apply/fix_modelines.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ function apply($input)
1111
$manual_ced_line = NULL;
1212
$output = "";
1313
foreach ($lines as $nr=>$line) {
14-
if (eregi("Keep this comment at the end of the file", $line)) {
14+
if (preg_match("/Keep this comment at the end of the file/i", $line)) {
1515

1616
// we're on top of the comment
1717
if ($nr + 20 < $numlines) {

scripts/aspell.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ function recurse($dir) {
5252
foreach (glob("$dir/*") as $filename) {
5353
if (is_dir($filename)) {
5454
recurse($filename);
55-
} elseif (eregi('\\.xml$', $filename)) {
55+
} elseif (preg_match('/\\.xml$/i', $filename)) {
5656
//~ echo "$filename\n";
5757
$file = file_get_contents($filename);
5858
$file = preg_replace_callback('~(<!\\[CDATA\\[)(.*)(\\]\\]>)~sU', "callback_htmlentities", $file);

0 commit comments

Comments
 (0)