Description: public static void fun_ref (Ref_test ref_out){
Ref_test ref_in=new Ref_test()
ref_in.s1="in"
//ref_out.s1="out"
ref_out=ref_in //漏洞!!ref_out 指向ref_in ,
//那么当函数退出后,ref_out就会自动指向原来的堆!!!
System.out.println("fun_ref() ref_out.s1="+ref_out.s1)
}
To Search:
File list (Check if you may need any files):
String_int
..........\.classpath
..........\.project
..........\bin
..........\...\string_int
..........\...\..........\fun.class
..........\...\..........\fun_class.class
..........\...\..........\Fun_ref.class
..........\...\..........\fun_String.class
..........\...\..........\p.class
..........\...\..........\Point.class
..........\...\..........\Ref_test.class
..........\...\..........\stingObject.class
..........\...\..........\String_int.class
..........\src
..........\...\string_int
..........\...\..........\fun.java
..........\...\..........\fun_class.java
..........\...\..........\Fun_ref.java
..........\...\..........\fun_String.java
..........\...\..........\stingObject.java
..........\...\..........\String_int.java