Created
December 20, 2013 05:01
-
-
Save Cergoo/8050580 to your computer and use it in GitHub Desktop.
[]byte to int
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func read_int32(data []byte) int32 { | |
return int32(uint32(data[0]) + uint32(data[1])<<8 + uint32(data[2])<<16 + uint32(data[3])<<24) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment