mirror of
https://github.com/golang/sys.git
synced 2026-02-08 03:36:03 +03:00
85d149506305e7abe0aca5ad5ac4b1fce82ccd11
Add Major, Minor and Mkdev functions for converting devices numbers to their major/minor components and vice versa. The functions follow the behavior of glibc's corresponding macros. Also add an explanatory comment about the device number format, so the magic numbers make more sense. Test the conversion macros with some well-known device numbers for devices which should be present on any Linux system. Fixes golang/go#8106 Change-Id: Id336317985d6ac85ee83bc54e5f23703257c9121 Reviewed-on: https://go-review.googlesource.com/50550 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This repository holds supplemental Go packages for low-level interactions with the operating system. To submit changes to this repository, see http://golang.org/doc/contribute.html.
Description
Languages
Go
85.8%
Assembly
12.3%
Shell
1.7%
C
0.1%