cmd/mkpkg: allow zero files in a package.

Signed-off-by: David Anderson <danderson@tailscale.com>
This commit is contained in:
David Anderson 2021-05-04 21:58:39 -07:00 committed by Dave Anderson
parent 7fab244614
commit 1c6946f971

View File

@ -21,6 +21,9 @@
// into a map of filePathOnDisk -> filePathInPackage.
func parseFiles(s string) (map[string]string, error) {
ret := map[string]string{}
if len(s) == 0 {
return ret, nil
}
for _, f := range strings.Split(s, ",") {
fs := strings.Split(f, ":")
if len(fs) != 2 {