Skip to content

Commit

Permalink
Fix wrong md5 value (#167)
Browse files Browse the repository at this point in the history
  • Loading branch information
gavinfish committed Jan 2, 2020
1 parent c14a8cb commit 3eac90d
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
import hudson.remoting.VirtualChannel;
import jenkins.MasterToSlaveFileCallable;
import jenkins.model.Jenkins;
import org.apache.commons.codec.binary.Hex;
import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.io.FileUtils;
import org.apache.commons.lang.StringUtils;
Expand Down Expand Up @@ -452,8 +453,8 @@ public UploadResult call() throws Exception {
String md;
byte[] mdBytes;
try (InputStream is = src.read()) {
md = DigestUtils.md5Hex(is);
mdBytes = DigestUtils.md5(is);
md = Hex.encodeHexString(mdBytes);
}

ImmutablePair<Integer, String> response;
Expand Down

0 comments on commit 3eac90d

Please sign in to comment.