mirror of
https://github.com/moparisthebest/pacman
synced 2024-12-23 00:08:50 -05:00
Merge branch 'maint'
This commit is contained in:
commit
0d1263af26
@ -141,7 +141,7 @@ Options
|
|||||||
|
|
||||||
*TotalDownload*::
|
*TotalDownload*::
|
||||||
When downloading, display the amount downloaded, download rate, ETA,
|
When downloading, display the amount downloaded, download rate, ETA,
|
||||||
and completed percentage of the entire download list list rather
|
and completed percentage of the entire download list rather
|
||||||
than the percent of each individual download target. The progress
|
than the percent of each individual download target. The progress
|
||||||
bar is still based solely on the current file download.
|
bar is still based solely on the current file download.
|
||||||
|
|
||||||
|
@ -276,7 +276,7 @@ static int extract_single_file(struct archive *archive,
|
|||||||
struct archive_entry *entry, pmpkg_t *newpkg, pmpkg_t *oldpkg,
|
struct archive_entry *entry, pmpkg_t *newpkg, pmpkg_t *oldpkg,
|
||||||
pmtrans_t *trans, pmdb_t *db)
|
pmtrans_t *trans, pmdb_t *db)
|
||||||
{
|
{
|
||||||
const char *entryname; /* the name of the file in the archive */
|
char entryname[PATH_MAX]; /* the name of the file in the archive */
|
||||||
mode_t entrymode;
|
mode_t entrymode;
|
||||||
char filename[PATH_MAX]; /* the actual file we're extracting */
|
char filename[PATH_MAX]; /* the actual file we're extracting */
|
||||||
int needbackup = 0, notouch = 0;
|
int needbackup = 0, notouch = 0;
|
||||||
@ -286,7 +286,7 @@ static int extract_single_file(struct archive *archive,
|
|||||||
ARCHIVE_EXTRACT_TIME;
|
ARCHIVE_EXTRACT_TIME;
|
||||||
int errors = 0;
|
int errors = 0;
|
||||||
|
|
||||||
entryname = archive_entry_pathname(entry);
|
strncpy(entryname, archive_entry_pathname(entry), PATH_MAX);
|
||||||
entrymode = archive_entry_mode(entry);
|
entrymode = archive_entry_mode(entry);
|
||||||
|
|
||||||
memset(filename, 0, PATH_MAX); /* just to be sure */
|
memset(filename, 0, PATH_MAX); /* just to be sure */
|
||||||
|
@ -61,7 +61,7 @@ int _alpm_remove_loadtarget(pmtrans_t *trans, pmdb_t *db, char *name)
|
|||||||
RET_ERR(PM_ERR_TRANS_DUP_TARGET, -1);
|
RET_ERR(PM_ERR_TRANS_DUP_TARGET, -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if((info = _alpm_db_scan(db, name)) == NULL) {
|
if((info = _alpm_db_get_pkgfromcache(db, name)) == NULL) {
|
||||||
_alpm_log(PM_LOG_DEBUG, "could not find %s in database\n", name);
|
_alpm_log(PM_LOG_DEBUG, "could not find %s in database\n", name);
|
||||||
RET_ERR(PM_ERR_PKG_NOT_FOUND, -1);
|
RET_ERR(PM_ERR_PKG_NOT_FOUND, -1);
|
||||||
}
|
}
|
||||||
@ -77,7 +77,7 @@ int _alpm_remove_loadtarget(pmtrans_t *trans, pmdb_t *db, char *name)
|
|||||||
}
|
}
|
||||||
|
|
||||||
_alpm_log(PM_LOG_DEBUG, "adding %s in the targets list\n", info->name);
|
_alpm_log(PM_LOG_DEBUG, "adding %s in the targets list\n", info->name);
|
||||||
trans->packages = alpm_list_add(trans->packages, info);
|
trans->packages = alpm_list_add(trans->packages, _alpm_pkg_dup(info));
|
||||||
|
|
||||||
return(0);
|
return(0);
|
||||||
}
|
}
|
||||||
@ -107,12 +107,12 @@ int _alpm_remove_prepare(pmtrans_t *trans, pmdb_t *db, alpm_list_t **data)
|
|||||||
alpm_list_t *i;
|
alpm_list_t *i;
|
||||||
for(i = lp; i; i = i->next) {
|
for(i = lp; i; i = i->next) {
|
||||||
pmdepmissing_t *miss = (pmdepmissing_t *)i->data;
|
pmdepmissing_t *miss = (pmdepmissing_t *)i->data;
|
||||||
pmpkg_t *info = _alpm_db_scan(db, miss->target);
|
pmpkg_t *info = _alpm_db_get_pkgfromcache(db, miss->target);
|
||||||
if(info) {
|
if(info) {
|
||||||
if(!_alpm_pkg_find(alpm_pkg_get_name(info), trans->packages)) {
|
if(!_alpm_pkg_find(alpm_pkg_get_name(info), trans->packages)) {
|
||||||
_alpm_log(PM_LOG_DEBUG, "pulling %s in the targets list\n",
|
_alpm_log(PM_LOG_DEBUG, "pulling %s in the targets list\n",
|
||||||
alpm_pkg_get_name(info));
|
alpm_pkg_get_name(info));
|
||||||
trans->packages = alpm_list_add(trans->packages, info);
|
trans->packages = alpm_list_add(trans->packages, _alpm_pkg_dup(info));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
_alpm_log(PM_LOG_ERROR, _("could not find %s in database -- skipping\n"),
|
_alpm_log(PM_LOG_ERROR, _("could not find %s in database -- skipping\n"),
|
||||||
|
Loading…
Reference in New Issue
Block a user