Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm/md5driver.c
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2007-06-04 23:32:38 -0400
committerDan McGee <dan@archlinux.org>2007-06-04 23:32:38 -0400
commit26e3db423abeb4cb5704f89dc0fc50a767f19b47 (patch)
treed6574466cb8846d162719a49dc38df8f59acbca4 /lib/libalpm/md5driver.c
parent466b79bf8f9a9b3f37a1a754b40320df9f2f1b4e (diff)
parent64d36db5f45db15997c6a3987d6f4b0ce147df27 (diff)
Merge branch 'alpm.c_cleanup' into frontend_config
Conflicts: lib/libalpm/alpm.c
Diffstat (limited to 'lib/libalpm/md5driver.c')
-rw-r--r--lib/libalpm/md5driver.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/libalpm/md5driver.c b/lib/libalpm/md5driver.c
index 80b90564..e2821bf0 100644
--- a/lib/libalpm/md5driver.c
+++ b/lib/libalpm/md5driver.c
@@ -41,6 +41,20 @@ documentation and/or software.
#define MDUpdate _alpm_MD5Update
#define MDFinal _alpm_MD5Final
+/** Get the md5 sum of file.
+ * @param name name of the file
+ * @return the checksum on success, NULL on error
+ * @addtogroup alpm_misc
+ */
+char SYMEXPORT *alpm_get_md5sum(char *name)
+{
+ ALPM_LOG_FUNC;
+
+ ASSERT(name != NULL, return(NULL));
+
+ return(_alpm_MDFile(name));
+}
+
char* _alpm_MDFile(char *filename)
{
FILE *file;