mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-11-09 19:50:26 +03:00
Fixed a deletion error.
This commit is contained in:
parent
645e7ec43e
commit
746624144c
10
data.c
10
data.c
@ -241,7 +241,7 @@ int index_add(const char *fn, const char *id)
|
||||
}
|
||||
|
||||
|
||||
int index_del(const char *fn, const char *md5)
|
||||
int index_del_md5(const char *fn, const char *md5)
|
||||
/* deletes an md5 from an index */
|
||||
{
|
||||
int status = 404;
|
||||
@ -279,6 +279,14 @@ int index_del(const char *fn, const char *md5)
|
||||
}
|
||||
|
||||
|
||||
int index_del(const char *fn, const char *id)
|
||||
/* deletes an id from an index */
|
||||
{
|
||||
xs *md5 = xs_md5_hex(id, strlen(id));
|
||||
return index_del_md5(fn, md5);
|
||||
}
|
||||
|
||||
|
||||
int index_in_md5(const char *fn, const char *md5)
|
||||
/* checks if the md5 is already in the index */
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user