From a0a376bf0eca00cce974de12c2f275006c1281ee Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Fri, 28 Aug 2009 17:55:58 +0000 Subject: Take out unnecessary defines --- scripts/synctwitterfriends.php | 2 -- scripts/twitterqueuehandler.php | 2 -- scripts/twitterstatusfetcher.php | 2 -- 3 files changed, 6 deletions(-) diff --git a/scripts/synctwitterfriends.php b/scripts/synctwitterfriends.php index 2cb7525ea..b30e700a1 100755 --- a/scripts/synctwitterfriends.php +++ b/scripts/synctwitterfriends.php @@ -19,8 +19,6 @@ */ define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); -define('STATUSNET', true); -define('LACONICA', true); // compatibility $shortoptions = 'di::'; $longoptions = array('id::', 'debug'); diff --git a/scripts/twitterqueuehandler.php b/scripts/twitterqueuehandler.php index 992141f9d..ce4d824d0 100755 --- a/scripts/twitterqueuehandler.php +++ b/scripts/twitterqueuehandler.php @@ -19,8 +19,6 @@ */ define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); -define('STATUSNET', true); -define('LACONICA', true); // compatibility $shortoptions = 'i::'; $longoptions = array('id::'); diff --git a/scripts/twitterstatusfetcher.php b/scripts/twitterstatusfetcher.php index 6dca6f75b..3cdf1867a 100755 --- a/scripts/twitterstatusfetcher.php +++ b/scripts/twitterstatusfetcher.php @@ -19,8 +19,6 @@ */ define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); -define('STATUSNET', true); -define('LACONICA', true); // compatibility // Tune number of processes and how often to poll Twitter // XXX: Should these things be in config.php? -- cgit v1.2.3-54-g00ecf From 3368452ebf3c738933b05e902c277296684e280b Mon Sep 17 00:00:00 2001 From: Craig Andrews Date: Fri, 28 Aug 2009 16:18:05 -0400 Subject: Add % and ~ as valid characters in the path, querystring, and fragment parts of URLs --- lib/util.php | 10 +++++----- tests/URLDetectionTest.php | 4 ++++ 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/lib/util.php b/lib/util.php index 8a56be55d..edc08d4c1 100644 --- a/lib/util.php +++ b/lib/util.php @@ -421,7 +421,7 @@ function common_replace_urls_callback($text, $callback, $notice_id = null) { '|'. '(?:(?:mailto|aim|tel|xmpp):)'. ')'. - '(?:[\pN\pL\-\_\+]+(?::[\pN\pL\-\_\+]+)?\@)?'. //user:pass@ + '(?:[\pN\pL\-\_\+\%\~]+(?::[\pN\pL\-\_\+\%\~]+)?\@)?'. //user:pass@ '(?:'. '(?:'. '\[[\pN\pL\-\_\:\.]+(?127.0.0.1:99'), array('127.0.0.1/test.php', '127.0.0.1/test.php'), + array('127.0.0.1/~test', + '127.0.0.1/~test'), + array('127.0.0.1/test%20stuff', + '127.0.0.1/test%20stuff'), array('http://[::1]:99/test.php', 'http://[::1]:99/test.php'), array('http://::1/test.php', -- cgit v1.2.3-54-g00ecf