00001 /* 00002 lockerror.h - error declarations for all locks (mutex, rwlocks, cond vars) 00003 00004 Copyright (C) Lumiera.org 00005 2010, Christian Thaeter <ct@pipapo.org> 00006 00007 This program is free software; you can redistribute it and/or 00008 modify it under the terms of the GNU General Public License as 00009 published by the Free Software Foundation; either version 2 of the 00010 License, or (at your option) any later version. 00011 00012 This program is distributed in the hope that it will be useful, 00013 but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 GNU General Public License for more details. 00016 00017 You should have received a copy of the GNU General Public License 00018 along with this program; if not, write to the Free Software 00019 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00020 */ 00021 00022 #ifndef LUMIERA_LOCKERRORS_H 00023 #define LUMIERA_LOCKERRORS_H 00024 00025 #include "lib/error.h" 00026 00027 /* fatal errors (EINVAL usually), we DIE on these, shall never ever happen on a correct program */ 00028 LUMIERA_ERROR_DECLARE (LOCK_ACQUIRE); 00029 LUMIERA_ERROR_DECLARE (LOCK_RELEASE); 00030 LUMIERA_ERROR_DECLARE (LOCK_DESTROY); 00031 00032 /* runtime errors */ 00033 LUMIERA_ERROR_DECLARE (LOCK_INVAL); 00034 LUMIERA_ERROR_DECLARE (LOCK_BUSY); 00035 LUMIERA_ERROR_DECLARE (LOCK_DEADLK); 00036 LUMIERA_ERROR_DECLARE (LOCK_PERM); 00037 LUMIERA_ERROR_DECLARE (LOCK_TIMEOUT); 00038 LUMIERA_ERROR_DECLARE (LOCK_AGAIN); 00039 00043 void 00044 lumiera_lockerror_set (int err, struct nobug_flag* flag, const struct nobug_context ctx); 00045 00046 #endif 00047 /* 00048 // Local Variables: 00049 // mode: C 00050 // c-file-style: "gnu" 00051 // indent-tabs-mode: nil 00052 // End: 00053 */
1.5.6