added: loggin to upload.cpp
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@571 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
parent
cd74d1887a
commit
7e0014865e
|
@ -10,6 +10,8 @@
|
|||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <cstdio>
|
||||
#include <errno.h>
|
||||
#include <string.h>
|
||||
#include "content.h"
|
||||
#include "../core/request.h"
|
||||
#include "../core/data.h"
|
||||
|
@ -64,9 +66,20 @@ struct stat sb;
|
|||
}
|
||||
else
|
||||
{
|
||||
int err = errno;
|
||||
|
||||
// !! skasowac takze plik z bazy danych
|
||||
log << log1 << "Content: can't move the tmp file from: " << tmp_filename;
|
||||
log << log1 << ", to: " << path << logend;
|
||||
log << log1 << "Content: can't move the tmp file from: " << tmp_filename;
|
||||
log << log1 << ", to: " << path;
|
||||
log << log1 << ", errno: " << err;
|
||||
|
||||
const char * err_msg = strerror(err);
|
||||
|
||||
if( err_msg )
|
||||
log << log1 << ": " << err_msg;
|
||||
|
||||
log << logend;
|
||||
|
||||
request.status = Error::permission_denied;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue