From 0686fec8399e01adacd1633d6ad624ee2d5b6d9c Mon Sep 17 00:00:00 2001
From: Chantry Xavier <shiningxc@gmail.com>
Date: Sun, 4 Nov 2007 20:53:34 +0100
Subject: Remove the newline automatically added by alpm_logaction.

This way, _alpm_logaction behaves like _alpm_log, and gives more control.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
---
 src/pacman/callback.c | 6 +++---
 src/pacman/sync.c     | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

(limited to 'src')

diff --git a/src/pacman/callback.c b/src/pacman/callback.c
index a68b0a48..5160b3b3 100644
--- a/src/pacman/callback.c
+++ b/src/pacman/callback.c
@@ -193,7 +193,7 @@ void cb_trans_evt(pmtransevt_t event, void *data1, void *data2)
 			if(config->noprogressbar) {
 				printf(_("done.\n"));
 			}
-			snprintf(str, LOG_STR_LEN, "installed %s (%s)",
+			snprintf(str, LOG_STR_LEN, "installed %s (%s)\n",
 			         alpm_pkg_get_name(data1),
 			         alpm_pkg_get_version(data1));
 			alpm_logaction(str);
@@ -207,7 +207,7 @@ void cb_trans_evt(pmtransevt_t event, void *data1, void *data2)
 			if(config->noprogressbar) {
 			    printf(_("done.\n"));
 			}
-			snprintf(str, LOG_STR_LEN, "removed %s (%s)",
+			snprintf(str, LOG_STR_LEN, "removed %s (%s)\n",
 			         alpm_pkg_get_name(data1),
 			         alpm_pkg_get_version(data1));
 			alpm_logaction(str);
@@ -221,7 +221,7 @@ void cb_trans_evt(pmtransevt_t event, void *data1, void *data2)
 			if(config->noprogressbar) {
 				printf(_("done.\n"));
 			}
-			snprintf(str, LOG_STR_LEN, "upgraded %s (%s -> %s)",
+			snprintf(str, LOG_STR_LEN, "upgraded %s (%s -> %s)\n",
 			         (char *)alpm_pkg_get_name(data1),
 			         (char *)alpm_pkg_get_version(data2),
 			         (char *)alpm_pkg_get_version(data1));
diff --git a/src/pacman/sync.c b/src/pacman/sync.c
index eedea7d4..d0ab8938 100644
--- a/src/pacman/sync.c
+++ b/src/pacman/sync.c
@@ -411,7 +411,7 @@ int sync_trans(alpm_list_t *targets, int sync_only)
 	if(config->op_s_sync) {
 		/* grab a fresh package list */
 		printf(_(":: Synchronizing package databases...\n"));
-		alpm_logaction("synchronizing package lists");
+		alpm_logaction("synchronizing package lists\n");
 		if(!sync_synctree(config->op_s_sync, sync_dbs)) {
 			fprintf(stderr, _("error: failed to synchronize any databases\n"));
 			retval = 1;
@@ -426,7 +426,7 @@ int sync_trans(alpm_list_t *targets, int sync_only)
 		alpm_list_t *pkgs, *i;
 
 		printf(_(":: Starting full system upgrade...\n"));
-		alpm_logaction("starting full system upgrade");
+		alpm_logaction("starting full system upgrade\n");
 		if(alpm_trans_sysupgrade() == -1) {
 			fprintf(stderr, _("error: %s\n"), alpm_strerrorlast());
 			retval = 1;
-- 
cgit v1.2.3-2-g168b