mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-22 12:22:06 +01:00
TeeBCPGInputStream: Annotate byte[] arg as @Nonnull
This commit is contained in:
parent
78cb2ec3d0
commit
3cea985365
1 changed files with 3 additions and 1 deletions
|
@ -19,6 +19,8 @@ import org.bouncycastle.openpgp.PGPOnePassSignature;
|
|||
import org.bouncycastle.openpgp.PGPSignature;
|
||||
import org.pgpainless.algorithm.OpenPgpPacket;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
|
||||
/**
|
||||
* Since we need to update signatures with data from the underlying stream, this class is used to tee out the data.
|
||||
* Unfortunately we cannot simply override {@link BCPGInputStream#read()} to tee the data out though, since
|
||||
|
@ -121,7 +123,7 @@ public class TeeBCPGInputStream {
|
|||
}
|
||||
|
||||
@Override
|
||||
public int read(byte[] b, int off, int len) throws IOException {
|
||||
public int read(@Nonnull byte[] b, int off, int len) throws IOException {
|
||||
if (last != -1) {
|
||||
outputStream.write(last);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue