Skip to content

Commit

Permalink
更新README,exe文件更改为静态编译后的版本
Browse files Browse the repository at this point in the history
  • Loading branch information
ankanch committed Mar 6, 2017
1 parent c33eeb5 commit 98c88e0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,14 @@ this is a test by Kanch.

**注意:如果在-r模式先仅给出一个值(l-range或者r-range),程序将会从文件起始位置读取到给定值位置。

# 编译本代码

请使用以下命令编译:

```
g++ -o brw -static -static-libgcc -static-libstdc++ binrw.cpp
```

# 其它

您可以在GPL协议下自由修改本代码。
Expand Down
4 changes: 2 additions & 2 deletions binrw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ int main(int argc,char**argv)
*/
if(argc == 1){
cout<<STRING_USAGE<<endl;
}else if( argc == 4){
}else if( argc == 4 || strcmp(argv[3],MODE_ALL) == 0 || strcmp(argv[3],MODE_REDUCT) == 0){
//选中为读取整个文件的二进制代码
if( strcmp(argv[3],MODE_ALL) == 0 ){
//开始处理
Expand All @@ -36,7 +36,7 @@ int main(int argc,char**argv)
return -1;
}

}else if( argc == 6 or argc == 5){
}else if( argc == 6 or argc == 5 or strcmp(argv[3],MODE_RANGE) == 0){
//选中为读取指定区间二进制代码,如果为5个参数,则默认为从 0 到 r-range
//如果为6个参数,则为 l-range 到 r-range
if( strcmp(argv[3],MODE_RANGE) != 0 ){
Expand Down
Binary file modified brw.exe
Binary file not shown.

0 comments on commit 98c88e0

Please sign in to comment.