#include <config.h>
#include "sbuild-lock.h"
#include <cerrno>
#include <cstdlib>
#include <unistd.h>
#include <boost/format.hpp>
#include <lockdev.h>
Include dependency graph for sbuild-lock.cc:
Go to the source code of this file.
Typedefs | |
typedef std::pair< lock::error_code, const char * > | emap |
Functions | |
void | alarm_handler (int ignore) |
Handle the SIGALRM signal. | |
Variables | |
emap | init_errors [] |
This is a list of the supported error codes. | |
volatile bool | lock_timeout = false |
typedef std::pair<lock::error_code,const char *> emap [static] |
Definition at line 39 of file sbuild-lock.cc.
void @36::alarm_handler | ( | int | ignore | ) | [static] |
Handle the SIGALRM signal.
ignore | the signal number. |
Definition at line 83 of file sbuild-lock.cc.
emap init_errors[] [static] |
Initial value:
{ emap(lock::TIMEOUT_HANDLER, N_("Failed to set timeout handler")), emap(lock::TIMEOUT_SET, N_("Failed to set timeout")), emap(lock::TIMEOUT_CANCEL, N_("Failed to cancel timeout")), emap(lock::LOCK, N_("Failed to lock file")), emap(lock::LOCK_TIMEOUT, N_("Failed to lock file (timed out after %4% seconds)")), emap(lock::DEVICE_LOCK, N_("Failed to lock device")), emap(lock::DEVICE_LOCK_TIMEOUT, N_("Failed to lock device (timed out after %4% seconds; lock held by PID %5%)")), emap(lock::DEVICE_TEST, N_("Failed to test device lock")), emap(lock::DEVICE_UNLOCK, N_("Failed to unlock device")), emap(lock::DEVICE_UNLOCK, N_("Failed to unlock device (timed out after %4% seconds; lock held by PID %5%)")) }
It's used to construct the real error codes map.
Definition at line 45 of file sbuild-lock.cc.
volatile bool lock_timeout = false [static] |