wintun: fix GUID leading zero padding

Signed-off-by: Simon Rozman <simon@rozman.si>
This commit is contained in:
Simon Rozman 2019-05-09 11:45:14 +02:00 committed by Jason A. Donenfeld
parent b16b0e4cf7
commit dcb8f1aa6b

View file

@ -37,5 +37,5 @@ func FromString(str string) (*windows.GUID, error) {
// The resulting string is uppercase.
//
func ToString(guid *windows.GUID) string {
return fmt.Sprintf("{%06X-%04X-%04X-%04X-%012X}", guid.Data1, guid.Data2, guid.Data3, guid.Data4[:2], guid.Data4[2:])
return fmt.Sprintf("{%08X-%04X-%04X-%04X-%012X}", guid.Data1, guid.Data2, guid.Data3, guid.Data4[:2], guid.Data4[2:])
}