mirror of
https://github.com/golang/sys.git
synced 2026-02-08 03:36:03 +03:00
These were apparently overlooked in CL 357329, CL 294490, CL 296889, and other various updates to this module. (I noticed them via gopls while investigating golang/go#49466.) Updates golang/go#41184 Change-Id: Id042bb6fe5282e6d528e9315acf2ad29d0df58ba Reviewed-on: https://go-review.googlesource.com/c/sys/+/362577 Trust: Bryan C. Mills <bcmills@google.com> Run-TryBot: Bryan C. Mills <bcmills@google.com> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Go Bot <gobot@golang.org>
24 lines
496 B
Go
24 lines
496 B
Go
// Copyright 2012 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
//go:build windows
|
|
// +build windows
|
|
|
|
package main
|
|
|
|
import (
|
|
"syscall"
|
|
)
|
|
|
|
// BUG(brainman): MessageBeep Windows api is broken on Windows 7,
|
|
// so this example does not beep when runs as service on Windows 7.
|
|
|
|
var (
|
|
beepFunc = syscall.MustLoadDLL("user32.dll").MustFindProc("MessageBeep")
|
|
)
|
|
|
|
func beep() {
|
|
beepFunc.Call(0xffffffff)
|
|
}
|