1
0
mirror of https://github.com/moparisthebest/pacman synced 2025-02-28 17:31:52 -05:00

Merge branch 'maint'

This commit is contained in:
Dan McGee 2008-04-07 19:19:34 -05:00
commit 83c4b2aebb
5 changed files with 17 additions and 3 deletions

View File

@ -176,8 +176,8 @@ AC_FUNC_FORK
AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK
AC_FUNC_MKTIME
AC_TYPE_SIGNAL
AC_CHECK_FUNCS([realpath regcomp strcasecmp strdup strerror strnlen \
strndup strrchr strsep strstr strverscmp uname geteuid])
AC_CHECK_FUNCS([geteuid realpath regcomp strcasecmp strdup strerror \
strndup strrchr strsep strstr strverscmp swprintf uname])
# Enable large file support if available
AC_SYS_LARGEFILE

View File

@ -20,7 +20,7 @@
# Original http://phraktured.net/config/bin/pacdiff
diffprog=${DIFFPROG:-vimdiff}
for x in $(find /etc/ -name *.pacnew -o -name *.pacorig -o -name *.pacsave)
for x in $(find /etc/ -name "*.pacnew" -o -name "*.pacorig" -o -name "*.pacsave")
do
echo "File: ${x%.pac*}"
chk="$(cmp $x ${x%.pac*})"

View File

@ -1,4 +1,5 @@
.deps
.libs
pacman
pacman.exe
pacman.static

View File

@ -361,7 +361,17 @@ void cb_trans_progress(pmtransprog_t event, const char *pkgname, int percent,
len = strlen(opr) + ((pkgname) ? strlen(pkgname) : 0) + 2;
wcstr = calloc(len, sizeof(wchar_t));
/* print our strings to the alloc'ed memory */
#if defined(HAVE_SWPRINTF)
wclen = swprintf(wcstr, len, L"%s %s", opr, pkgname);
#else
/* because the format string was simple, we can easily do this without
* using swprintf, although it is probably not as safe/fast. The max
* chars we can copy is decremented each time by subtracting the length
* of the already printed/copied wide char string. */
wclen = mbstowcs(wcstr, opr, len);
wclen += mbstowcs(wcstr + wclen, " ", len - wclen);
wclen += mbstowcs(wcstr + wclen, pkgname, len - wclen);
#endif
wcwid = wcswidth(wcstr, wclen);
padwid = textlen - wcwid;
/* if padwid is < 0, we need to trim the string so padwid = 0 */

3
src/util/.gitignore vendored
View File

@ -1,5 +1,8 @@
.deps
.libs
vercmp
vercmp.exe
testpkg
testpkg.exe
testdb
testdb.exe