Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cellular pkg - Get rid of deprecated split() function #322

Merged
merged 3 commits into from
Mar 7, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions net/pfSense-pkg-cellular/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

PORTNAME= pfSense-pkg-cellular
PORTVERSION= 1.1.4
PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= # empty
DISTFILES= # empty
Expand Down
4 changes: 2 additions & 2 deletions net/pfSense-pkg-cellular/files/usr/local/pkg/cellular.inc
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ function get_devices() {
$out = array();

foreach ($serialports as $port) {
$spl = split("/", $port);
$spl = explode("/", $port);
$out[$spl[2]] = array("name" => $port, "value" => $spl[2]);
}

Expand Down Expand Up @@ -140,7 +140,7 @@ function cellular_validate_input($post, &$input_errors) {
// Custom Status AT Command
if ($post['statuscmd'] != '') {
if (!preg_match('/^[A-Z0-9 _,;+=?"*#]*$/', $post['statuscmd'])) {
$input_errors[] = "The 'Custom Status AT Command' field may only contain A-Z, 0-9 and some other characters matching the /^[A-Z0-9 _,;+=?\"*#-]*$/ regex.";
$input_errors[] = "The 'Custom Status AT Command' field may only contain A-Z, 0-9 and some other characters matching the /^[A-Z0-9 _,;+=?\"*#]*$/ regex.";
}
}

Expand Down