aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--routers/repo/view.go2
-rw-r--r--vendor/github.com/gogits/git-module/tree_entry.go4
-rw-r--r--vendor/vendor.json6
3 files changed, 7 insertions, 5 deletions
diff --git a/routers/repo/view.go b/routers/repo/view.go
index f073afeb..623b7fee 100644
--- a/routers/repo/view.go
+++ b/routers/repo/view.go
@@ -46,7 +46,7 @@ func renderDirectory(ctx *context.Context, treeLink string) {
}
entries.Sort()
- ctx.Data["Files"], err = entries.GetCommitsInfo(ctx.Repo.Commit, ctx.Repo.TreePath, setting.Repository.CommitsFetchConcurrency)
+ ctx.Data["Files"], err = entries.GetCommitsInfoWithCustomConcurrency(ctx.Repo.Commit, ctx.Repo.TreePath, setting.Repository.CommitsFetchConcurrency)
if err != nil {
ctx.Handle(500, "GetCommitsInfo", err)
return
diff --git a/vendor/github.com/gogits/git-module/tree_entry.go b/vendor/github.com/gogits/git-module/tree_entry.go
index 8d2ea8e2..54574035 100644
--- a/vendor/github.com/gogits/git-module/tree_entry.go
+++ b/vendor/github.com/gogits/git-module/tree_entry.go
@@ -113,6 +113,8 @@ func (tes Entries) Sort() {
sort.Sort(tes)
}
+var defaultConcurrency = runtime.NumCPU()
+
type commitInfo struct {
entryName string
infos []interface{}
@@ -136,7 +138,7 @@ func (tes Entries) GetCommitsInfoWithCustomConcurrency(commit *Commit, treePath
}
if maxConcurrency <= 0 {
- maxConcurrency = runtime.NumCPU()
+ maxConcurrency = defaultConcurrency
}
// Length of taskChan determines how many goroutines (subprocesses) can run at the same time.
diff --git a/vendor/vendor.json b/vendor/vendor.json
index 903b5a16..cf4ee883 100644
--- a/vendor/vendor.json
+++ b/vendor/vendor.json
@@ -159,10 +159,10 @@
"revisionTime": "2016-08-10T03:50:02Z"
},
{
- "checksumSHA1": "bCfvbFm5XS4leTIpRaHEFtvaeYU=",
+ "checksumSHA1": "92bIqzmK6S5Pnq9HzqWva5mSDh4=",
"path": "github.com/gogits/git-module",
- "revision": "5ef701a1cd1e63b7037f23cf2878e5ee749207c0",
- "revisionTime": "2017-02-14T22:20:55Z"
+ "revision": "47f896db1a82dc746d8cfd2930e4b29a2bd75e2c",
+ "revisionTime": "2017-02-15T09:08:23Z"
},
{
"checksumSHA1": "xvG+RgJODQqlmdAkHUQK2TyLR88=",