Skip to content

Instantly share code, notes, and snippets.

@tdshipley
Last active August 29, 2015 14:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tdshipley/f0ffc976c9e3e13c578f to your computer and use it in GitHub Desktop.
Save tdshipley/f0ffc976c9e3e13c578f to your computer and use it in GitHub Desktop.
isJPEG function body
result = false
if (fileBlock[0] == 0xff && fileBlock[1] == 0xd8 && fileBlock[2] == 0xff && (fileBlock[3] == 0xe0 || fileBlock[3] == 0x0e1)) {
result = true
}
return result
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment