Commit 79284cae authored by Robert Griesemer's avatar Robert Griesemer

gofmt'ed src/cmd

R=rsc
http://go/go-review/1024004
parent 07b6becc
......@@ -86,7 +86,7 @@ var (
)
var fsTree RWValue; // *Directory tree of packages, updated with each sync
var fsTree RWValue // *Directory tree of packages, updated with each sync
func init() {
......@@ -224,7 +224,7 @@ func (dir *Directory) lookup(path string) *Directory {
return d;
}
}
return nil
return nil;
}
return dir.lookup(dpath).lookup(dname);
......@@ -425,7 +425,7 @@ func dirFmt(w io.Writer, x interface{}, format string) {
func removePrefix(s, prefix string) string {
if strings.HasPrefix(s, prefix) {
return s[len(prefix) : len(s)];
return s[len(prefix):len(s)];
}
return s;
}
......@@ -761,7 +761,7 @@ func (h *httpHandler) getPageInfo(path string) PageInfo {
func (h *httpHandler) ServeHTTP(c *http.Conn, r *http.Request) {
path := r.Url.Path;
path = path[len(h.pattern) : len(path)];
path = path[len(h.pattern):len(path)];
// canonicalize URL path and redirect if necessary
if canonical := pathutil.Clean(h.pattern + path) + "/"; r.Url.Path != canonical {
......@@ -797,7 +797,7 @@ func (h *httpHandler) ServeHTTP(c *http.Conn, r *http.Request) {
_, pkgname := pathutil.Split(pathutil.Clean(path));
title = "Command " + pkgname;
default:
title = "Command " + info.PDoc.PackageName
title = "Command " + info.PDoc.PackageName;
}
}
......@@ -885,4 +885,3 @@ func indexer() {
time.Sleep(1*60e9); // try once a minute
}
}
......@@ -98,7 +98,7 @@ func exec(c *http.Conn, args []string) (status int) {
// Maximum directory depth, adjust as needed.
const maxDirDepth = 24;
const maxDirDepth = 24
func dosync(c *http.Conn, r *http.Request) {
args := []string{"/bin/sh", "-c", *syncCmd};
......
......@@ -125,7 +125,8 @@ func (p *ebnfParser) parseTerm() bool {
func (p *ebnfParser) parseSequence() {
for p.parseTerm() {}
for p.parseTerm() {
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment