Skip to content

Commit

Permalink
JS Code format; ver updated.
Browse files Browse the repository at this point in the history
  • Loading branch information
JinnLynn committed May 9, 2012
1 parent 28f8f96 commit 1de13ac
Showing 1 changed file with 10 additions and 17 deletions.
27 changes: 10 additions & 17 deletions genpac.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

# ********************************************************************** #

VERSION = '0.1a'
VERSION = '0.2'
# 调试模式
DEBUGMODE = True

Expand Down Expand Up @@ -228,49 +228,42 @@ def CreatePacFile(gfwlistRules, userRules):
var length = 0;
length = directUserRegexpList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if(regExpMatch(url, directUserRegexpList[i])) return D;
}
length = directUserWildcardList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if (shExpMatch(url, directUserWildcardList[i])) return D;
}
length = proxyUserRegexpList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if(regExpMatch(url, proxyUserRegexpList[i])) return P;
}
length = proxyUserWildcardList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if(shExpMatch(url, proxyUserWildcardList[i])) return P;
}
length = directRegexpList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if(regExpMatch(url, directRegexpList[i])) return D;
}
length = directWildcardList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if (shExpMatch(url, directWildcardList[i])) return D;
}
length = proxyRegexpList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if(regExpMatch(url, proxyRegexpList[i])) return P;
}
length = proxyWildcardList.length;
for (i = 0; i < length; i++)
{
for (i = 0; i < length; i++) {
if(shExpMatch(url, proxyWildcardList[i])) return P;
}
Expand Down

0 comments on commit 1de13ac

Please sign in to comment.