File: 0003-fix-32bit-ftbfs.patch

package info (click to toggle)
golang-google-api 0.61.0-6
  • links: PTS, VCS
  • area: main
  • in suites: experimental, forky, sid, trixie
  • size: 209,156 kB
  • sloc: sh: 183; makefile: 22; python: 4
file content (16 lines) | stat: -rw-r--r-- 698 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
From: Mathias Gibbens <gibmat@debian.org>
Description: Fix FTBFS on 32bit systems. A better fix would be to properly change the type of max to int64, but that quickly snowballs out beyond this test code.
Debian-Bug: https://bugs.debian.org/1103120
diff --git a/iterator/iterator_test.go b/iterator/iterator_test.go
index acdd653f36..8bb7f432fa 100644
--- a/iterator/iterator_test.go
+++ b/iterator/iterator_test.go
@@ -39,7 +39,7 @@ type service struct {
 func (s *service) List(pageSize int, pageToken string) ([]int, string, error) {
 	max := s.max
 	if max == 0 {
-		max = math.MaxInt64
+		max = math.MaxInt32
 	}
 	// Never give back any more than s.max.
 	if pageSize <= 0 || pageSize > max {