Commit c1b72a7
committed
gerrit: allow setAuth to fallthrough to netrc lookup
When git has no http cookies, the request for http cookies
will fail because git will exit(1). Ignore this failure
because the output is properly tested either way. This allows
authentication to fallthrough to the netrc lookup.
Correct the netrc lookup under windows. git reads the netrc
file as "_netrc" in the users home directory.
Add a warning at the end of the function that no authentication
was set.
Fixes golang/go#26782
Change-Id: I0ba94ff7fa4b6038d6117156dcc729ddf4616fdc
Reviewed-on: https://go-review.googlesource.com/127855
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>1 parent 24a3043 commit c1b72a7
1 file changed
+16
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
| |||
59 | 60 | | |
60 | 61 | | |
61 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
62 | 70 | | |
63 | 71 | | |
64 | 72 | | |
65 | 73 | | |
66 | 74 | | |
67 | 75 | | |
68 | 76 | | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
74 | 82 | | |
75 | 83 | | |
76 | 84 | | |
| |||
90 | 98 | | |
91 | 99 | | |
92 | 100 | | |
93 | | - | |
| 101 | + | |
| 102 | + | |
94 | 103 | | |
95 | 104 | | |
96 | 105 | | |
| |||
101 | 110 | | |
102 | 111 | | |
103 | 112 | | |
| 113 | + | |
104 | 114 | | |
105 | 115 | | |
106 | 116 | | |
| |||
0 commit comments