浏览代码

Restrict modules/graceful to non-windows build and shim the IsChild marker (#8537)

tags/v1.11.0-rc1
zeripath 4 年前
父节点
当前提交
d4cd4ed442
没有帐户链接到提交者的电子邮件

+ 2
- 0
modules/graceful/cleanup.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

+ 11
- 0
modules/graceful/graceful_windows.go 查看文件

@@ -0,0 +1,11 @@
// +build windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.
// This code is heavily inspired by the archived gofacebook/gracenet/net.go handler

package graceful

// This file contains shims for windows builds
const IsChild = false

+ 2
- 0
modules/graceful/net.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

+ 2
- 0
modules/graceful/restart.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

+ 2
- 0
modules/graceful/server.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

+ 2
- 0
modules/graceful/server_hooks.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

+ 2
- 0
modules/graceful/server_http.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

+ 2
- 0
modules/graceful/server_signals.go 查看文件

@@ -1,3 +1,5 @@
// +build !windows

// Copyright 2019 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

正在加载...
取消
保存