summaryrefslogtreecommitdiffstats
path: root/src/etc
diff options
context:
space:
mode:
authorRenato Botelho <renato@netgate.com>2017-03-02 16:49:42 -0300
committerRenato Botelho <renato@netgate.com>2017-03-02 16:49:42 -0300
commit79215c03e3b34e180e64394bf00b4373127c6778 (patch)
tree1ff1c58d3585435f9a2e4ea6b8ccbe45037b8a55 /src/etc
parent4485ad3189a2a9e295d088c63561e45f66da20d2 (diff)
parent117776e0c01e68a8b65584d86d7b8b56fe75c9d0 (diff)
downloadpfsense-79215c03e3b34e180e64394bf00b4373127c6778.zip
pfsense-79215c03e3b34e180e64394bf00b4373127c6778.tar.gz
Merge pull request #3576 from doktornotor/patch-7
Diffstat (limited to 'src/etc')
-rw-r--r--src/etc/inc/util.inc6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/etc/inc/util.inc b/src/etc/inc/util.inc
index 937f899..604c557 100644
--- a/src/etc/inc/util.inc
+++ b/src/etc/inc/util.inc
@@ -2689,4 +2689,10 @@ function get_duid_from_file() {
}
return($duid_ASCII);
}
+
+/* Replaces the Mac OS 9 and earlier (\r) and DOS/Windows (\r\n) newlines with the Unix equivalent (\n). */
+function unixnewlines($text) {
+ return preg_replace('/\r\n?/', "\n", $text);
+}
+
?>
OpenPOWER on IntegriCloud