~ubuntu-branches/ubuntu/lucid/pango1.0/lucid-security

« back to all changes in this revision

Viewing changes to pango/opentype/hb-open-type-private.hh

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2009-08-11 17:30:40 UTC
  • mfrom: (1.5.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20090811173040-zozfegyjkb39sep2
Tags: 1.25.2-0ubuntu1
New upstream version

Show diffs side-by-side

added added

removed removed

Lines of Context:
424
424
    return CONST_CAST(Type, *CONST_CHARP(base), offset);
425
425
  }
426
426
 
427
 
  bool sanitize (SANITIZE_ARG_DEF, const void *base) {
 
427
  inline bool sanitize (SANITIZE_ARG_DEF, const void *base) {
428
428
    SANITIZE_DEBUG ();
429
429
    if (!SANITIZE_OBJ (*this)) return false;
430
430
    unsigned int offset = *this;
431
431
    if (HB_UNLIKELY (!offset)) return true;
432
432
    return SANITIZE (CAST(Type, *DECONST_CHARP(base), offset)) || NEUTER (DECONST_CAST(OffsetType,*this,0), 0);
433
433
  }
434
 
  bool sanitize (SANITIZE_ARG_DEF, const void *base, const void *base2) {
 
434
  inline bool sanitize (SANITIZE_ARG_DEF, const void *base, const void *base2) {
435
435
    SANITIZE_DEBUG ();
436
436
    if (!SANITIZE_OBJ (*this)) return false;
437
437
    unsigned int offset = *this;
438
438
    if (HB_UNLIKELY (!offset)) return true;
439
439
    return SANITIZE_BASE (CAST(Type, *DECONST_CHARP(base), offset), base2) || NEUTER (DECONST_CAST(OffsetType,*this,0), 0);
440
440
  }
441
 
  bool sanitize (SANITIZE_ARG_DEF, const void *base, unsigned int user_data) {
 
441
  inline bool sanitize (SANITIZE_ARG_DEF, const void *base, unsigned int user_data) {
442
442
    SANITIZE_DEBUG ();
443
443
    if (!SANITIZE_OBJ (*this)) return false;
444
444
    unsigned int offset = *this;
471
471
  inline unsigned int get_size () const
472
472
  { return sizeof (len) + len * sizeof (array[0]); }
473
473
 
474
 
  bool sanitize (SANITIZE_ARG_DEF) {
 
474
  inline bool sanitize (SANITIZE_ARG_DEF) {
475
475
    SANITIZE_DEBUG ();
476
476
    if (!SANITIZE_GET_SIZE()) return false;
477
477
    /* Note; for non-recursive types, this is not much needed
482
482
    */
483
483
    return true;
484
484
  }
485
 
  bool sanitize (SANITIZE_ARG_DEF, const void *base) {
 
485
  inline bool sanitize (SANITIZE_ARG_DEF, const void *base) {
486
486
    SANITIZE_DEBUG ();
487
487
    if (!SANITIZE_GET_SIZE()) return false;
488
488
    unsigned int count = len;
491
491
        return false;
492
492
    return true;
493
493
  }
494
 
  bool sanitize (SANITIZE_ARG_DEF, const void *base, const void *base2) {
 
494
  inline bool sanitize (SANITIZE_ARG_DEF, const void *base, const void *base2) {
495
495
    SANITIZE_DEBUG ();
496
496
    if (!SANITIZE_GET_SIZE()) return false;
497
497
    unsigned int count = len;
500
500
        return false;
501
501
    return true;
502
502
  }
503
 
  bool sanitize (SANITIZE_ARG_DEF, const void *base, unsigned int user_data) {
 
503
  inline bool sanitize (SANITIZE_ARG_DEF, const void *base, unsigned int user_data) {
504
504
    SANITIZE_DEBUG ();
505
505
    if (!SANITIZE_GET_SIZE()) return false;
506
506
    unsigned int count = len;
547
547
  inline unsigned int get_size () const
548
548
  { return sizeof (len) + (len ? len - 1 : 0) * sizeof (array[0]); }
549
549
 
550
 
  bool sanitize (SANITIZE_ARG_DEF) {
 
550
  inline bool sanitize (SANITIZE_ARG_DEF) {
551
551
    SANITIZE_DEBUG ();
552
552
    if (!SANITIZE_GET_SIZE()) return false;
553
553
    /* Note; for non-recursive types, this is not much needed