• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: looking for a crc code
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: looking for a crc code


  • Subject: Re: looking for a crc code
  • From: Andrew Farmer <email@hidden>
  • Date: Sat, 14 Jun 2008 11:30:27 -0700

On 14 Jun 08, at 10:49, Michael Hall wrote:
I googled up this one. Might of taken more than a minute I'm afraid.
Checksum, Please
http://yamacdev.blogspot.com/2006/12/checksum-please.html

It suggests zlib which should always be available, shouldn't it?

Yep. There was recently a discussion of this on the list, actually.

fprintf(stdout,"crc=%i\n",crc);

Note that this'll print out the CRC as a signed integer, which is almost certainly not what you want.


Unfortunately, testing got sort of inconsistent results.
./testcrc
crc=-286616648

Like I said. If you convert this to hex, you'll get 0xeeea93b8, which is the correct CRC32 of "test".


doesn't seem to work out quite the same as...
crc32 test.txt
f783d7be

This is the CRC32 of "test\n". Watch your newlines. _______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: looking for a crc code
      • From: Michael Hall <email@hidden>
References: 
 >looking for a crc code (From: Angelo Chen <email@hidden>)
 >Re: looking for a crc code (From: Graham Cox <email@hidden>)
 >Re: looking for a crc code (From: Ilan Volow <email@hidden>)
 >Re: looking for a crc code (From: Jens Alfke <email@hidden>)
 >Re: looking for a crc code (From: Michael Hall <email@hidden>)

  • Prev by Date: Re: CoreAnimation removeFromSuperlayer flicker
  • Next by Date: Re: PDFView's NSPrintPanel : Determine if Print / Cancel clicked?
  • Previous by thread: Re: looking for a crc code
  • Next by thread: Re: looking for a crc code
  • Index(es):
    • Date
    • Thread