Add exception cause

This commit is contained in:
Andrew Gaul 2017-11-20 10:49:55 -08:00
parent a62494a117
commit 73c3b6024c
1 changed files with 2 additions and 2 deletions

View File

@ -192,7 +192,7 @@ public class Aws4SignerForAuthorizationHeader extends Aws4SignerBase {
try {
payloadStream = payload.openStream();
} catch (IOException e) {
throw new HttpException("unable to open payload stream to calculate AWS4 signature.");
throw new HttpException("unable to open payload stream to calculate AWS4 signature.", e);
}
try {
return base16().lowerCase().encode(hash(payloadStream));
@ -213,7 +213,7 @@ public class Aws4SignerForAuthorizationHeader extends Aws4SignerBase {
} catch (IOException e) {
// reset payload stream
throw new HttpException(
"unable to reset unrepeatable payload stream after calculating AWS4 signature.");
"unable to reset unrepeatable payload stream after calculating AWS4 signature.", e);
}
}
}