index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Dan McGee <dan@archlinux.org> | 2007-06-17 23:25:07 -0400 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2007-09-28 00:16:43 -0500 |
commit | f7bbfe4052ca1060d2d1021dacd77923d8ab6786 (patch) | |
tree | c1013c79b1148874ff30effe4c84c99eb69b5a86 /lib/libalpm/server.c | |
parent | 0758012b6617fd25f3af84853611b9adaf65f674 (diff) |
-rw-r--r-- | lib/libalpm/server.c | 13 |
diff --git a/lib/libalpm/server.c b/lib/libalpm/server.c index 5fdc41a6..8d9c6f87 100644 --- a/lib/libalpm/server.c +++ b/lib/libalpm/server.c @@ -187,22 +187,15 @@ int _alpm_downloadfiles_forreal(alpm_list_t *servers, const char *localpath, char output[PATH_MAX]; char *fn = (char *)lp->data; char pkgname[PKG_NAME_LEN]; - char *p; fileurl = url_for_file(server, fn); if(!fileurl) { return(-1); } - /* Try to get JUST the name of the package from the filename */ - memset(pkgname, 0, PKG_NAME_LEN); - if((p = strstr(fn, PKGEXT))) { - _alpm_pkg_splitname(fn, pkgname, NULL, 1); - } - if(!strlen(pkgname)) { - /* just use the raw filename if we can't find crap */ - strncpy(pkgname, fn, PKG_NAME_LEN); - } + /* use the raw filename for download progress */ + /* TODO maybe strip the normal pkg.tar.gz extension? */ + strncpy(pkgname, fn, PKG_NAME_LEN); _alpm_log(PM_LOG_DEBUG, "using '%s' for download progress\n", pkgname); snprintf(realfile, PATH_MAX, "%s%s", localpath, fn); |