Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-workhorse
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kazuhiko Shiozaki
gitlab-workhorse
Commits
c24ae03a
Commit
c24ae03a
authored
Nov 10, 2015
by
Marin Jankovski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More feedback fixes.
parent
c99c4302
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
15 deletions
+5
-15
archive.go
archive.go
+0
-2
git-http.go
git-http.go
+0
-4
lfs.go
lfs.go
+5
-9
No files found.
archive.go
View file @
c24ae03a
...
@@ -119,8 +119,6 @@ func handleGetArchive(w http.ResponseWriter, r *gitRequest) {
...
@@ -119,8 +119,6 @@ func handleGetArchive(w http.ResponseWriter, r *gitRequest) {
logContext
(
"handleGetArchive finalize cached archive"
,
err
)
logContext
(
"handleGetArchive finalize cached archive"
,
err
)
return
return
}
}
return
}
}
func
setArchiveHeaders
(
w
http
.
ResponseWriter
,
format
string
,
archiveFilename
string
)
{
func
setArchiveHeaders
(
w
http
.
ResponseWriter
,
format
string
,
archiveFilename
string
)
{
...
...
git-http.go
View file @
c24ae03a
...
@@ -55,8 +55,6 @@ func handleGetInfoRefs(w http.ResponseWriter, r *gitRequest) {
...
@@ -55,8 +55,6 @@ func handleGetInfoRefs(w http.ResponseWriter, r *gitRequest) {
logContext
(
"handleGetInfoRefs wait for subprocess"
,
err
)
logContext
(
"handleGetInfoRefs wait for subprocess"
,
err
)
return
return
}
}
return
}
}
func
handlePostRPC
(
w
http
.
ResponseWriter
,
r
*
gitRequest
)
{
func
handlePostRPC
(
w
http
.
ResponseWriter
,
r
*
gitRequest
)
{
...
@@ -132,8 +130,6 @@ func handlePostRPC(w http.ResponseWriter, r *gitRequest) {
...
@@ -132,8 +130,6 @@ func handlePostRPC(w http.ResponseWriter, r *gitRequest) {
logContext
(
"handlePostRPC wait for subprocess"
,
err
)
logContext
(
"handlePostRPC wait for subprocess"
,
err
)
return
return
}
}
return
}
}
func
subCommand
(
rpc
string
)
string
{
func
subCommand
(
rpc
string
)
string
{
...
...
lfs.go
View file @
c24ae03a
...
@@ -38,12 +38,9 @@ func lfsAuthorizeHandler(handleFunc serviceHandleFunc) serviceHandleFunc {
...
@@ -38,12 +38,9 @@ func lfsAuthorizeHandler(handleFunc serviceHandleFunc) serviceHandleFunc {
return
return
}
}
tmpDir
:=
r
.
StoreLFSPath
if
err
:=
os
.
Mkdir
(
r
.
StoreLFSPath
,
0700
);
err
!=
nil
{
if
_
,
err
:=
os
.
Stat
(
tmpDir
);
os
.
IsNotExist
(
err
)
{
fail500
(
w
,
"Couldn't create directory for storing LFS tmp objects."
,
err
)
if
err
:=
os
.
Mkdir
(
tmpDir
,
0700
);
err
!=
nil
{
return
fail500
(
w
,
"Couldn't create directory for storing LFS tmp objects."
,
err
)
return
}
}
}
handleFunc
(
w
,
r
)
handleFunc
(
w
,
r
)
...
@@ -56,13 +53,12 @@ func handleStoreLfsObject(w http.ResponseWriter, r *gitRequest) {
...
@@ -56,13 +53,12 @@ func handleStoreLfsObject(w http.ResponseWriter, r *gitRequest) {
body
=
r
.
Body
body
=
r
.
Body
defer
body
.
Close
()
defer
body
.
Close
()
tmpPath
:=
r
.
StoreLFSPath
file
,
err
:=
ioutil
.
TempFile
(
r
.
StoreLFSPath
,
r
.
LfsOid
)
file
,
err
:=
ioutil
.
TempFile
(
tmpPath
,
r
.
LfsOid
)
if
err
!=
nil
{
if
err
!=
nil
{
fail500
(
w
,
"Couldn't open tmp file for writing."
,
err
)
fail500
(
w
,
"Couldn't open tmp file for writing."
,
err
)
return
return
}
}
defer
os
.
Remove
(
tmpPath
)
defer
os
.
Remove
(
file
.
Name
()
)
defer
file
.
Close
()
defer
file
.
Close
()
hash
:=
sha256
.
New
()
hash
:=
sha256
.
New
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment