]> Cypherpunks repositories - gostls13.git/commit
encoding/base32: handle NoPadding in NewDecoder
authorGustav Westling <zegl@westling.xyz>
Wed, 16 May 2018 16:35:58 +0000 (16:35 +0000)
committerIan Lance Taylor <iant@golang.org>
Wed, 16 May 2018 21:15:03 +0000 (21:15 +0000)
commitc3d10e64b91652bf2a65411b2cac9ed7797fb53f
tree888548a44e78c9b8e7b09ddbec9e71a29905e03f
parent594a6bde3336cc6f0cd14256e980370c56c72a90
encoding/base32: handle NoPadding in NewDecoder

This change adds functionality to properly handle NoPadding in NewDecoder.

Removes the following expectations when using NoPadding:

* the input message length is a multiple of 8
* the input message length is 0, or longer than 7 characters

Fixes #25332

Change-Id: I7c38160df23f7e8da4f85a5629530016e7bf71f3
GitHub-Last-Rev: 68ab8d2291df5c69e647620f8ef82cc90e06db28
GitHub-Pull-Request: golang/go#25394
Reviewed-on: https://go-review.googlesource.com/113215
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/encoding/base32/base32.go
src/encoding/base32/base32_test.go