~ubuntu-branches/ubuntu/gutsy/vnc4/gutsy

« back to all changes in this revision

Viewing changes to unix/xc/extras/FreeType/lib/ttmutex.h

  • Committer: Bazaar Package Importer
  • Author(s): Ola Lundqvist
  • Date: 2006-05-15 20:35:17 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20060515203517-l4lre1ku942mn26k
Tags: 4.1.1+X4.3.0-10
* Correction of critical security issue. Thanks to Martin Kogler
  <e9925248@student.tuwien.ac.at> that informed me about the issue,
  and provided the patch.
  This flaw was originally found by Steve Wiseman of intelliadmin.com.
* Applied patch from Javier Kohen <jkohen@users.sourceforge.net> that
  inform the user that only 8 first characters of the password will
  actually be used when typing more than 8 characters, closes:
  #355619.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*******************************************************************
 
2
 *
 
3
 *  ttmutex.h                                                1.0
 
4
 *
 
5
 *    Mutual exclusion object / dummy generic interface.
 
6
 *
 
7
 *  Copyright 1996-1999 by
 
8
 *  David Turner, Robert Wilhelm, and Werner Lemberg.
 
9
 *
 
10
 *  This file is part of the FreeType project, and may only be used
 
11
 *  modified and distributed under the terms of the FreeType project
 
12
 *  license, LICENSE.TXT.  By continuing to use, modify, or distribute
 
13
 *  this file you indicate that you have read the license and
 
14
 *  understand and accept it fully.
 
15
 *
 
16
 *  Note:  This file provides a generic interface.  The implementation
 
17
 *         to compile depends on your system and the type of
 
18
 *         library you want to build (either singly-threaded,
 
19
 *         thread-safe or re-entrant).
 
20
 *
 
21
 *         Please read the technical documentation for more details.
 
22
 *
 
23
 ******************************************************************/
 
24
 
 
25
#ifndef TTMUTEX_H
 
26
#define TTMUTEX_H
 
27
 
 
28
#include "ttconfig.h"
 
29
 
 
30
 
 
31
  typedef  void*  TMutex;  /* typeless reference to a mutex */
 
32
 
 
33
#ifdef TT_CONFIG_OPTION_THREAD_SAFE /* thread-safe and re-entrant builds */
 
34
 
 
35
#define MUTEX_Create( mutex )   TT_Mutex_Create ( &(mutex) )
 
36
#define MUTEX_Destroy( mutex )  TT_Mutex_Delete ( &(mutex) )
 
37
#define MUTEX_Lock( mutex )     TT_Mutex_Lock   ( &(mutex) )
 
38
#define MUTEX_Release( mutex )  TT_Mutex_Release( &(mutex) )
 
39
 
 
40
  LOCAL_DEF void  TT_Mutex_Create ( TMutex*  mutex ); /* Create a new mutex */
 
41
  LOCAL_DEF void  TT_Mutex_Delete ( TMutex*  mutex ); /* Delete a mutex     */
 
42
  LOCAL_DEF void  TT_Mutex_Lock   ( TMutex*  mutex ); /* Lock a mutex.      */
 
43
  LOCAL_DEF void  TT_Mutex_Release( TMutex*  mutex ); /* Release a mutex    */
 
44
 
 
45
#else  /* for the single-thread build */
 
46
 
 
47
#define MUTEX_Create( mutex )   /* nothing */
 
48
#define MUTEX_Destroy( mutex )  /* nothing */
 
49
#define MUTEX_Lock( mutex )     /* nothing */
 
50
#define MUTEX_Release( mutex )  /* nothing */
 
51
 
 
52
  /* No code will be generated for mutex operations */
 
53
 
 
54
#endif /* TT_CONFIG_OPTION_THREAD_SAFE */
 
55
 
 
56
#endif /* TTMUTEX_H */
 
57
 
 
58
 
 
59
/* END */