2007-03-20 09:41:05 +00:00
|
|
|
#include "exclude.h"
|
|
|
|
|
|
|
|
void
|
2007-05-31 04:25:39 +00:00
|
|
|
iso_exclude_add_path(struct iso_hash_table *table, const char *path)
|
2007-03-20 09:41:05 +00:00
|
|
|
{
|
|
|
|
if (!path)
|
|
|
|
return;
|
|
|
|
|
2007-05-31 04:25:39 +00:00
|
|
|
table->num += iso_hash_insert(table->table, path);
|
2007-03-20 09:41:05 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2007-05-31 04:25:39 +00:00
|
|
|
iso_exclude_empty(struct iso_hash_table *table)
|
2007-03-20 09:41:05 +00:00
|
|
|
{
|
2007-05-31 04:25:39 +00:00
|
|
|
if (!table->num)
|
2007-03-20 09:41:05 +00:00
|
|
|
return;
|
|
|
|
|
2007-05-31 04:25:39 +00:00
|
|
|
iso_hash_empty(table->table);
|
|
|
|
table->num=0;
|
2007-03-20 09:41:05 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
int
|
2007-05-31 04:25:39 +00:00
|
|
|
iso_exclude_lookup(struct iso_hash_table *table, const char *path)
|
2007-03-20 09:41:05 +00:00
|
|
|
{
|
2007-05-31 04:25:39 +00:00
|
|
|
if (!table->num || !path)
|
2007-03-20 09:41:05 +00:00
|
|
|
return 0;
|
|
|
|
|
2007-05-31 04:25:39 +00:00
|
|
|
return iso_hash_lookup(table->table, path);
|
2007-03-20 09:41:05 +00:00
|
|
|
}
|