From aa501f2e44a7a08634609c4db4e635c4d1937df0 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Tue, 22 Jun 2010 18:29:34 +0200 Subject: small fixes to WatchCrashdumpArchiveDir code Signed-off-by: Denys Vlasenko --- src/Daemon/Daemon.cpp | 2 +- src/Daemon/abrt-handle-upload | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'src') diff --git a/src/Daemon/Daemon.cpp b/src/Daemon/Daemon.cpp index 2b56522b..e9db034d 100644 --- a/src/Daemon/Daemon.cpp +++ b/src/Daemon/Daemon.cpp @@ -434,7 +434,7 @@ static gboolean handle_inotify_cb(GIOChannel *gio, GIOCondition condition, gpoin { /* Default size: 128 simultaneous actions (about 1/2 meg) */ #define INOTIFY_BUF_SIZE ((sizeof(struct inotify_event) + FILENAME_MAX)*128) - /* Determine how much to read (it usualiiy is much smaller) */ + /* Determine how much to read (it usually is much smaller) */ /* NB: this variable _must_ be int-sized, ioctl expects that! */ int inotify_bytes = INOTIFY_BUF_SIZE; if (ioctl(g_io_channel_unix_get_fd(gio), FIONREAD, &inotify_bytes) != 0 diff --git a/src/Daemon/abrt-handle-upload b/src/Daemon/abrt-handle-upload index 3c02f257..82f52692 100644 --- a/src/Daemon/abrt-handle-upload +++ b/src/Daemon/abrt-handle-upload @@ -9,10 +9,10 @@ print_clean_and_die() { - printf "%s\n" "$*" - #echo delete_on_exit="$delete_on_exit" - test "$delete_on_exit" && rm -rf -- $delete_on_exit - exit $die_exitcode + printf "%s\n" "$*" + #echo delete_on_exit="$delete_on_exit" + test "$delete_on_exit" && rm -rf -- $delete_on_exit + exit $die_exitcode } die_exitcode=1 @@ -57,13 +57,13 @@ $unpacker <"$archive.working" | tar xf - -C "$tempdir" || print_clean_and_die "C # or one or more complete crashdump directories. # Checking second possibility first. if test -f "$tempdir/analyzer" && test -f "$tempdir/time" && test -f "$tempdir/uid"; then - echo 1 >"$tempdir/remote" + printf "1" >"$tempdir/remote" mv -- "$tempdir" "$abrt_dir" else for d in "$tempdir"/*; do - test -d "$d" || continue - echo 1 >"$tempdir/$d/remote" - mv -- "$d" "$abrt_dir" + test -d "$d" || continue + printf "1" >"$tempdir/$d/remote" + mv -- "$d" "$abrt_dir" done fi -- cgit