FULL PRODUCT VERSION :
java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) Client VM (build 16.3-b01, mixed mode, sharing)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.0.6002]
A DESCRIPTION OF THE PROBLEM :
for example if jartest.zip contains jartest.c and jartest.cpp then
jar xvf jartest.zip j
will extract both files as will
jar xvf jartest.zip jartest.c
so overwriting jartest.cpp
This is unexpected if this is a "feature"
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
echo cprogram > jartest.c
echo cplusprogram > jartest.cpp
jar cvf jartest.zip jartest.c jartest.cpp
jar xvf jartest.zip jartest.c
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Only jartest.c should be extracted
ACTUAL -
"c:\Program Files\Java\jdk1.6.0_20\bin\jar.exe" xvf jartest.zip jartest.c
inflated: jartest.c
inflated: jartest.cpp
REPRODUCIBILITY :
This bug can be reproduced always.
java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) Client VM (build 16.3-b01, mixed mode, sharing)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.0.6002]
A DESCRIPTION OF THE PROBLEM :
for example if jartest.zip contains jartest.c and jartest.cpp then
jar xvf jartest.zip j
will extract both files as will
jar xvf jartest.zip jartest.c
so overwriting jartest.cpp
This is unexpected if this is a "feature"
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
echo cprogram > jartest.c
echo cplusprogram > jartest.cpp
jar cvf jartest.zip jartest.c jartest.cpp
jar xvf jartest.zip jartest.c
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Only jartest.c should be extracted
ACTUAL -
"c:\Program Files\Java\jdk1.6.0_20\bin\jar.exe" xvf jartest.zip jartest.c
inflated: jartest.c
inflated: jartest.cpp
REPRODUCIBILITY :
This bug can be reproduced always.