Fix some problems with dangling links while removing a binpkg.
First remove all links, next files and last dirs. Only check the SHA256 hash for files, skip links and dirs. --HG-- extra : convert_revision : b1762d5e795959591c732f625d25adfd1840f592
This commit is contained in:
parent
aefe26d30c
commit
be170f0cb7
3 changed files with 28 additions and 18 deletions
|
@ -243,13 +243,17 @@ static int
|
|||
show_pkg_files(prop_object_t obj, void *arg, bool *loop_done)
|
||||
{
|
||||
struct show_files_cb *sfc = arg;
|
||||
const char *file = NULL, *sha256;
|
||||
const char *file = NULL, *sha256, *type;
|
||||
char *path = NULL;
|
||||
int rv = 0;
|
||||
|
||||
(void)loop_done;
|
||||
|
||||
prop_dictionary_get_cstring_nocopy(obj, "file", &file);
|
||||
prop_dictionary_get_cstring_nocopy(obj, "type", &type);
|
||||
if (strcmp(type, "file") != 0)
|
||||
return 0;
|
||||
|
||||
if (sfc->check_hash == false && file != NULL) {
|
||||
printf("%s\n", file);
|
||||
return 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue