Skip to content
Snippets Groups Projects
Verified Commit 8b356544 authored by Morgan Adamiec's avatar Morgan Adamiec
Browse files

libalpm: use null for no alpm_fileconflict_t->ctarget

parent 39c3cbdf
No related branches found
No related tags found
No related merge requests found
......@@ -269,7 +269,6 @@ static alpm_list_t *add_fileconflict(alpm_handle_t *handle,
STRDUP(conflict->file, filestr, goto error);
if(!pkg2) {
conflict->type = ALPM_FILECONFLICT_FILESYSTEM;
STRDUP(conflict->ctarget, "", goto error);
} else if(pkg2->origin == ALPM_PKG_FROM_LOCALDB) {
conflict->type = ALPM_FILECONFLICT_FILESYSTEM;
STRDUP(conflict->ctarget, pkg2->name, goto error);
......
......@@ -840,7 +840,7 @@ int sync_prepare_execute(void)
conflict->file, conflict->target, conflict->ctarget);
break;
case ALPM_FILECONFLICT_FILESYSTEM:
if(conflict->ctarget[0]) {
if(conflict->ctarget) {
printf(_("%s: %s exists in filesystem (owned by %s)\n"),
conflict->target, conflict->file, conflict->ctarget);
} else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment