# # patch "ChangeLog" # from [09578d73b8901070f5e9068cbbe2da269e3e9fe6] # to [5dcfd55a684cf7b13eeb0af6c73ad78f4e058903] # # patch "quick_alloc.hh" # from [5d073689e85c09f526bc33c685222818a4225c48] # to [597049a62d0a2e6af7df0b19f4945ec7d6458727] # # patch "sanity.hh" # from [56b8f42b629be5332bdc2aa2f142ec64a5699859] # to [327d38c4b4e0a26e734861ef263ee7c365f5ceb5] # --- ChangeLog +++ ChangeLog @@ -1,5 +1,12 @@ 2005-04-27 Richard Levitte + * quick_alloc.hh: Define QA_SUPPORTED when quick allocation is + supported. + * sanity.hh: Only defined the QA(T) variants of checked_index() + when QA_SUPPORTED is defined. + +2005-04-27 Richard Levitte + * database.cc (selector_to_certname): Add a case for commands::sel_cert. --- quick_alloc.hh +++ quick_alloc.hh @@ -1,8 +1,9 @@ #ifndef __QUICK_ALLOC__ #define __QUICK_ALLOC__ #if defined(__GNUC__) && __GNUC__ < 3 || (__GNUC__ == 3 && __GNUC_MINOR__ < 4) # define QA(T) std::__allocator< T, std::__single_client_alloc > +# define QA_SUPPORTED #else # define QA(T) std::allocator< T > #endif --- sanity.hh +++ sanity.hh @@ -158,6 +158,7 @@ return v[i]; } +#ifdef QA_SUPPORTED template inline T & checked_index(std::vector & v, typename std::vector::size_type i, @@ -183,6 +184,7 @@ global_sanity.index_failure(vec, index, v.size(), i, file, line); return v[i]; } +#endif // QA_SUPPORTED #define idx(v, i) checked_index((v), (i), #v, #i, __FILE__, __LINE__)