OSDN Git Service

pkwk_touch_file() also corrects the ownership
authorhenoheno <henoheno>
Sun, 4 Feb 2007 11:42:36 +0000 (20:42 +0900)
committerumorigu <umorigu@gmail.com>
Tue, 25 Nov 2014 16:32:44 +0000 (01:32 +0900)
plugin/online.inc.php

index 9dd9b54..11df1e5 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 // $Id: online.inc.php,v 1.12 2007/02/10 06:21:53 henoheno Exp $
 // Copyright (C)
-//   2002-2005 PukiWiki Developers Team
+//   2002-2005, 2007 PukiWiki Developers Team
 //   2001-2002 Originally written by yu-ji
 // License: GPL v2 or (at your option) any later version
 //
@@ -65,9 +65,7 @@ function plugin_online_itself($type = 0)
 // & $count == Number of online users
 function plugin_online_check_online(& $count, $host = '')
 {
-       if (! file_exists(PLUGIN_ONLINE_USER_LIST) &&
-           ! @touch(PLUGIN_ONLINE_USER_LIST))
-               return FALSE;
+       if (pkwk_touch_file(PLUGIN_ONLINE_USER_LIST)) return FALSE;
 
        // Open
        $fp = @fopen(PLUGIN_ONLINE_USER_LIST, 'r');