From: <tak...@us...> - 2013-01-29 09:09:56
|
Revision: 7683 http://gfarm.svn.sourceforge.net/gfarm/?rev=7683&view=rev Author: takuya-i Date: 2013-01-29 09:09:49 +0000 (Tue, 29 Jan 2013) Log Message: ----------- * clarify log messages * add error handling Modified Paths: -------------- gfarm_samba/trunk/gfarm.c Modified: gfarm_samba/trunk/gfarm.c =================================================================== --- gfarm_samba/trunk/gfarm.c 2013-01-29 08:53:42 UTC (rev 7682) +++ gfarm_samba/trunk/gfarm.c 2013-01-29 09:09:49 UTC (rev 7683) @@ -1038,14 +1038,22 @@ char *rpath, *skip_path; gfarm_error_t e; - gflog_debug(GFARM_MSG_UNFIXED, "realpath: path %s", path); + gflog_debug(GFARM_MSG_UNFIXED, "realpath: input: %s", path); e = gfs_realpath(path, &rpath); if (e == GFARM_ERR_NO_ERROR) { skip_path = strdup(skip_prefix(rpath)); free(rpath); + if (skip_path != NULL) { + gflog_debug(GFARM_MSG_UNFIXED, "realpath: result: %s", + skip_path); + } else { + gflog_error(GFARM_MSG_UNFIXED, "realpath: no memory"); + errno = ENOMEM; + } return (skip_path); } - gflog_error(GFARM_MSG_UNFIXED, "realpath: %s", gfarm_error_string(e)); + gflog_error(GFARM_MSG_UNFIXED, "realpath: %s: %s", + path, gfarm_error_string(e)); errno = gfarm_error_to_errno(e); return (NULL); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |