GNOME Bugzilla – Bug 524827
Should use glib to calculate md5 hash (last.fm)
Last modified: 2008-09-06 21:20:39 UTC
g_checksum_* will do the job. lib/md5.h could probably be removed as well.
g_checksum_* was added in glib 2.16 which was released this month, so for now, g_checksum_* use would have to be optional (or rb would need to ship a copy of gchecksum.[ch] for people with older glibs)
The minimum GLib req was upped, so this should be an easy bug to fix now.
Created attachment 115794 [details] [review] Use glib to calculate md5 hashes for last.fm plugin Tested and works. lib/md5.{c,h} can now be removed.
I worked on this just now, but I seem to be a bit late. Anyway, I thought I'd mention that the DAAP plugin has its own MD5 code as well. To be precise, it's in rb-daap-hash.c.
The code in the DAAP plugin is not really MD5. One of the constants is slightly different (lines 275-282). I've committed the patch. Thanks, Johannes.
*** Bug 524826 has been marked as a duplicate of this bug. ***