Skip to content

Commit

Permalink
modify file flag to O_WRONLY (#49)
Browse files Browse the repository at this point in the history
* modify file flag to O_WRONLY.

* fix ci
  • Loading branch information
taoyuanyuan authored Jun 4, 2021
1 parent c7178e9 commit 6e8f5a0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ coverage-local:

coverage:
docker build --rm -t ${BUILD_IMAGE} build/contrib/builder/binary
docker run --rm -v $(GOPATH):/go -v $(shell pwd):/go/src/${PROJECT_NAME} -w /go/src/${PROJECT_NAME} ${BUILD_IMAGE} make coverage-local
docker run --rm -v $(shell go env GOPATH):/go -v $(shell pwd):/go/src/${PROJECT_NAME} -w /go/src/${PROJECT_NAME} ${BUILD_IMAGE} make coverage-local
2 changes: 1 addition & 1 deletion log/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ func (l *Logger) start() error {
if err := os.MkdirAll(filepath.Dir(l.output), 0755); err != nil {
return err
}
file, err := os.OpenFile(l.output, os.O_RDWR|os.O_CREATE|os.O_APPEND, 0644)
file, err := os.OpenFile(l.output, os.O_WRONLY|os.O_CREATE|os.O_APPEND, 0644)
if err != nil {
return err
}
Expand Down

0 comments on commit 6e8f5a0

Please sign in to comment.