Pascal Peridont 19 年 前
コミット
c4777f1f43
1 ファイル変更1 行追加1 行削除
  1. 1 1
      std/mtwin/web/Request.hx

+ 1 - 1
std/mtwin/web/Request.hx

@@ -96,7 +96,7 @@ class Request {
 	public function getIP() : String{
 		var ip = Web.getClientIP();
 		var xf = Web.getClientHeader("X-Forwarded-For");
-		if( REG_IP.match( xf ) ){
+		if( xf != null && REG_IP.match( xf ) ){
 			var fip = REG_IP.matched(1);
 			if( !~/^(127\.0\.0\.1|192\.168\..*|172\.16\..*|10\..*|224\..*|240\..*)$/.match(fip) ){
 				ip = fip;