cmd/go: fix detached heads that are remnants of bad git clones.
cmd/go: fix detached heads that are remnants of bad git clones.

Fixes issue 6042.

R=adg
CC=golang-dev
https://codereview.appspot.com/12923043

pombredanne/go-deleteme,apparentlymart/golang,tv42/old-go,apparentlymart/golang,tv42/old-go,pombredanne/go-deleteme,tv42/old-go,pombredanne/go-deleteme,apparentlymart/golang,apparentlymart/golang,pombredanne/go-deleteme,tv42/old-go,apparentlymart/golang,tv42/old-go,pombredanne/go-deleteme,pombredanne/go-deleteme,tv42/old-go,tv42/old-go,pombredanne/go-deleteme,apparentlymart/golang,apparentlymart/golang