Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lib_base
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sikang
lib_base
Commits
5deac342
Commit
5deac342
authored
Oct 29, 2019
by
sikang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
upadte
parent
26b8e67e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
8 deletions
+6
-8
python/tools/garble/java_garble.py
+3
-6
python/tools/garble/model/logic_model.java
+3
-2
No files found.
python/tools/garble/java_garble.py
View file @
5deac342
...
...
@@ -170,17 +170,14 @@ class JavaGarble:
curly_braces
=
line
.
count
(
"{"
)
curly_braces
-=
line
.
count
(
"}"
)
if
curly_braces
>
0
:
if
curly_braces
>=
1
:
curly_braces
+=
line
.
count
(
"{"
)
curly_braces
-=
line
.
count
(
"}"
)
# 一个花括号表示在方法的直接作用域内
if
curly_braces
==
1
:
if
"return"
in
line
:
curly_braces
=
-
10000
continue
if
";
\n
"
in
line
:
if
";
\n
"
in
line
and
len
(
line
)
>
10
:
line
+=
"
\n
%
s"
%
self
.
__insert_code
()
fout
.
write
(
line
)
...
...
python/tools/garble/model/logic_model.java
View file @
5deac342
...
...
@@ -31,10 +31,10 @@ while((int)${name} < (${name} - 1)){
$
{
content
}
}
//sep
if
(
android
.
text
.
TextUtils
.
isEmpty
(
Build
.
BOARD
)){
if
(
android
.
text
.
TextUtils
.
isEmpty
(
android
.
os
.
Build
.
BOARD
)){
$
{
content
}
}
//sep
if
(
Build
.
DEVICE
.
contains
(
"${string}"
)){
if
(
android
.
os
.
Build
.
DEVICE
.
contains
(
"${string}"
)){
$
{
content
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment