Files
winix/functions/run.cpp
Tomasz Sowa 7468e7a36c added: namespace Winix over all *.h/*.cpp files
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@948 e52654a7-88a9-db11-a3e9-0013d4bc506e
2014-02-12 16:30:49 +00:00

55 lines
630 B
C++
Executable File

/*
* This file is a part of Winix
* and is not publicly distributed
*
* Copyright (c) 2008-2014, Tomasz Sowa
* All rights reserved.
*
*/
#include "run.h"
namespace Winix
{
namespace Fun
{
Run::Run()
{
fun.url = L"run";
}
void Run::MakePost()
{
MakeGet();
}
void Run::MakeGet()
{
if( !cur->request->is_item )
{
log << log1 << "Content: Run function requires an item" << logend;
cur->request->status = WINIX_ERR_NO_ITEM;
return;
}
if( !system->HasReadExecAccess(cur->request->item) )
{
cur->request->status = WINIX_ERR_PERMISSION_DENIED;
return;
}
}
} // namespace
} // namespace Winix