From 7a5c797c9f6ba1b967b078a7392f19c044463564 Mon Sep 17 00:00:00 2001 From: germeier Date: Fri, 11 Apr 2003 22:53:09 +0000 Subject: small error messages changes --- mpiosh/callback.c | 21 +++++++++++++++------ mpiosh/mpiosh.c | 3 ++- 2 files changed, 17 insertions(+), 7 deletions(-) (limited to 'mpiosh') diff --git a/mpiosh/callback.c b/mpiosh/callback.c index 8006e5f..28c0284 100644 --- a/mpiosh/callback.c +++ b/mpiosh/callback.c @@ -2,7 +2,7 @@ * * Author: Andreas Büsching * - * $Id: callback.c,v 1.36 2003/04/11 21:42:58 germeier Exp $ + * $Id: callback.c,v 1.37 2003/04/11 22:53:10 germeier Exp $ * * Copyright (C) 2001 Andreas Büsching * @@ -240,10 +240,13 @@ mpiosh_cmd_open(char *args[]) UNUSED(args); mpiosh.dev = mpio_init(mpiosh_callback_init); + printf("\n"); - if (mpiosh.dev == NULL) - printf("error: could not open connection MPIO player\n"); + if (mpiosh.dev == NULL) { + mpio_perror("ERROR"); + printf("could not open connection MPIO player\n"); + } else printf("connection to MPIO player is opened\n"); @@ -484,8 +487,11 @@ mpiosh_cmd_mput(char *args[]) if (mpiosh_cancel) debug("operation cancelled by user\n"); - if (written) + if (written) { mpio_sync(mpiosh.dev, mpiosh.card); + } else { + printf("file not found!\n"); + } } BYTE @@ -560,7 +566,7 @@ mpiosh_cmd_mdel(char *args[]) because the directory has changed !! */ if (r != MPIO_OK) { - printf("ERROR: %s\n", mpio_strerror(r)); + mpio_perror("ERROR"); p = mpio_dentry_next(mpiosh.dev, mpiosh.card, p); break; } @@ -576,8 +582,11 @@ mpiosh_cmd_mdel(char *args[]) i++; } regfree(®ex); - if (deleted) + if (deleted) { mpio_sync(mpiosh.dev, mpiosh.card); + } else { + printf("file not found!\n"); + } } diff --git a/mpiosh/mpiosh.c b/mpiosh/mpiosh.c index 2f39c04..5ddf5c6 100644 --- a/mpiosh/mpiosh.c +++ b/mpiosh/mpiosh.c @@ -2,7 +2,7 @@ /* * - * $Id: mpiosh.c,v 1.23 2002/11/13 23:05:28 germeier Exp $ + * $Id: mpiosh.c,v 1.24 2003/04/11 22:53:10 germeier Exp $ * * Author: Andreas Büsching * @@ -108,6 +108,7 @@ main(int argc, char *argv[]) { } if (!mpiosh.dev && interactive) { + printf("ERROR: %s\n", mpio_strerror(mpio_errno())); printf("could not find MPIO player.\n"); } -- cgit v1.2.3