diff --git a/modules/ssh/ssh.go b/modules/ssh/ssh.go index 15ba02a2b..f724c60fb 100644 --- a/modules/ssh/ssh.go +++ b/modules/ssh/ssh.go @@ -91,6 +91,7 @@ func handleServerConn(keyID string, chans <-chan ssh.NewChannel) { return } + req.Reply(true, nil); go io.Copy(input, ch) io.Copy(ch, stdout) io.Copy(ch.Stderr(), stderr) diff --git a/routers/repo/repo.go b/routers/repo/repo.go index d60ec6883..1c4d6a158 100644 --- a/routers/repo/repo.go +++ b/routers/repo/repo.go @@ -57,7 +57,7 @@ func checkContextUser(ctx *middleware.Context, uid int64) *models.User { } // Check ownership of organization. - if !org.IsOrganization() || !org.IsOwnedBy(ctx.User.Id) { + if !org.IsOrganization() || !(ctx.User.IsAdmin || org.IsOwnedBy(ctx.User.Id) { ctx.Error(403) return nil } diff --git a/templates/repo/diff.tmpl b/templates/repo/diff.tmpl index 656896841..4b2f43476 100644 --- a/templates/repo/diff.tmpl +++ b/templates/repo/diff.tmpl @@ -1,7 +1,7 @@ {{template "base/head" .}}
{{template "repo/header" .}} -
+
{{if .IsDiffCompare }} {{template "repo/commits_table" .}} {{else}}