The problem is that jar tvf
only allows one file to be passed in.
The for loop runs the files one by one
jar tvf 1.jar; jar tvf 2.jar; ...
However, xargs tries to fit as many arguments on one line as possible. Thus it's trying the following:
jar tvf 1.jar 2.jar ...
You can verify this by placing an echo in your command:
for f in `find . -name "*.jar"`; do echo jar tvf $f; done
find . -name "*.jar" | xargs echo jar tvf
The proper solution is the tell xargs to only use one parameter per command:
find . -name "*.jar" | xargs -n 1 jar tvf
or
find . -name "*.jar" | xargs -I{} jar tvf {} # Find style parameter placement