aboutsummaryrefslogtreecommitdiff
path: root/lib/lua/src/luac.c
diff options
context:
space:
mode:
authorAndrew Zyabin <schastlilya@gmail.com>2017-05-31 10:16:58 +0000
committerLoic Blot <loic.blot@unix-experience.fr>2017-06-03 20:02:42 +0200
commitb5912d7407e261ff30faf137c27418c75cdd661e (patch)
treeba1eca1883510edc6129db695b20ffd240883a6b /lib/lua/src/luac.c
parentd7e829f272052ec0eef996095b22256e7ec64284 (diff)
Translated using Weblate (Russian)
Currently translated at 96.1% (985 of 1024 strings)
Diffstat (limited to 'lib/lua/src/luac.c')
0 files changed, 0 insertions, 0 deletions
ght notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ #include "jmutex.h" JMutex::JMutex() { initialized = false; } JMutex::~JMutex() { if (initialized) pthread_mutex_destroy(&mutex); } int JMutex::Init() { if (initialized) return ERR_JMUTEX_ALREADYINIT; pthread_mutex_init(&mutex,NULL); initialized = true; return 0; } int JMutex::Lock() { if (!initialized) return ERR_JMUTEX_NOTINIT; pthread_mutex_lock(&mutex); return 0; } int JMutex::Unlock() { if (!initialized) return ERR_JMUTEX_NOTINIT; pthread_mutex_unlock(&mutex); return 0; }