Ignore:
Timestamp:
2011/05/17 16:15:29 (13 years ago)
Author:
Seasoft
Message:

#1309 (ADMIN_ALLOW_HOSTS が空文字や未定義の場合にエラーとならないようにする)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_11-dev/data/class/pages/admin/LC_Page_Admin.php

    r20870 r20928  
    4747        //IP制限チェック 
    4848        $allow_hosts = unserialize(ADMIN_ALLOW_HOSTS); 
    49         if(count($allow_hosts) > 0){ 
    50             if(array_search($_SERVER["REMOTE_ADDR"],$allow_hosts) === FALSE){ 
     49        if (is_array($allow_hosts) && count($allow_hosts) > 0) { 
     50            if (array_search($_SERVER["REMOTE_ADDR"],$allow_hosts) === FALSE) { 
    5151                SC_Utils_Ex::sfDispError(AUTH_ERROR); 
    5252            } 
Note: See TracChangeset for help on using the changeset viewer.