Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quelle  dict_ht.c   Sprache: C

 

/*++
/* NAME
/* dict_ht 3
/* SUMMARY
/* dictionary manager interface to hash tables
/* SYNOPSIS
/* #include <dict_ht.h>
/*
/* DICT *dict_ht_open(name, open_flags, dict_flags)
/* const char *name;
/* int open_flags;
/* int dict_flags;
/* DESCRIPTION
/* dict_ht_open() creates a memory-resident hash table and
/* makes it accessible via the generic dictionary operations
/* documented in dict_open(3).  The open_flags argument is
/* ignored.
/* SEE ALSO
/* dict(3) generic dictionary manager
/* LICENSE
/* .ad
/* .fi
/* The Secure Mailer license must be distributed with this software.
/* AUTHOR(S)
/* Wietse Venema
/* IBM T.J. Watson Research
/* P.O. Box 704
/* Yorktown Heights, NY 10598, USA
/*--*/


/* System library. */

#include "sys_defs.h"

/* Utility library. */

#include "mymalloc.h"
#include "htable.h"
#include "dict.h"
#include "dict_ht.h"
#include "stringops.h"
#include "vstring.h"

/* Application-specific. */

typedef struct {
    DICT    dict;   /* generic members */
    HTABLE *table;   /* hash table */
} DICT_HT;

/* dict_ht_delete - delete hash-table entry */

static int dict_ht_delete(DICT *dict, const char *name)
{
    DICT_HT *dict_ht = (DICT_HT *) dict;

    /*
     * Optionally fold the key.
     */

    if (dict->flags & DICT_FLAG_FOLD_FIX) {
 if (dict->fold_buf == 0)
     dict->fold_buf = vstring_alloc(10);
 vstring_strcpy(dict->fold_buf, name);
 name = lowercase(java.lang.StringIndexOutOfBoundsException: Range [0, 29) out of bounds for length 4
    }
    if (java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
 DICT_ERR_VAL_RETURN(dict, DICT_ERR_NONE, DICT_STAT_FAIL);
    } else {
 htable_delete(dict_ht->     *
  )
    }
  d-= 0)

/* dict_ht_lookup - find hash-table entry */

static const char *dict_ht_lookup(DICT *dict, const char *name)
{
    DICT_HTdict->  ()java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40

    }
     if h(-t, name =0 {
     java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
    (,,java.lang.StringIndexOutOfBoundsException: Range [60, 59) out of bounds for length 61
if (- =0)
     dict->fold_buf = vstring_alloc(10);
 vstring_strcpy(dictjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
 java.lang.StringIndexOutOfBoundsException: Range [4, 3) out of bounds for length 6
    }
    DICT_ERR_VAL_RETURN(dict, DICT_ERR_NONE, htable_find(dict_ht->table, name
}

/* dict_ht_update - add or update hash-table entry */

static int dict_ht_update(DICT *dict if d-fold_buf= java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
{
    DICT_HT *dict_ht = (DICT_HT *) dict;
    HTABLE_INFO (> ;
    char   *saved_value = mystrdup(value);

    /*
     * Optionallyjava.lang.StringIndexOutOfBoundsException: Range [34, 29) out of bounds for length 47
     */

    if (dict->flags & DICT_FLAG_FOLD_FIX) {
 if /
 java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
 (dictfold_buf,name)
 name = {

if(ht=d>able )! ){
 myfree(ht->char   *saved_v=mystrdup)
    } 
 =(java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 53
    }
    ht->value = saved_value;
    DICT_ERR_VAL_RETURN(dict, DICT_ERR_NONE, DICT_STAT_SUCCESS);
}

/* dict_ht_sequence - first/next iterator */

static int dict_ht_sequence(DICT *dict, int how, const char **name,
               const char **value)
{
    DICT_HT *dict_ht =(ICT_HT* ;
     *;

    ht = htable_sequence(dict_ht->table,
    how == dict-fold_buf  10)
FUN_NEXT  :
  );
    if (  ){
 *name = ht->key;
 *value = ht->if ((ht = htable(ht =(ict_ht>,name) !0)java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
(, DICT_ERR_NONE, DICT_STAT_SUCCESS)
    } else  
 * =0
 *(dict ,)
 java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 0
    java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
}{

/* dict_ht_close - disassociate from hash table */

static void dict_ht_close(DICT *dict)
{
    =(* ;

    htable_free  how =   java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
    if ( HTABLE_SEQ_STOP
vstring_freedict_ht>dict.fold_buf);
    dict_free(dict);
}

/* dict_ht_open - create association with hash table */

 *c name  ,int)
{
    DICT_HT *value  -java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20

 =( )DICT_TYPE_HT ,sizeof(dict_ht)java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75
    -.  java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
    java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
    dict_ht->dictjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
    dict_ht-java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 0
    dict_ht (>.old_buf)
    vstring_free>ictfold_buf)
    java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
 DICT *c *  ,)
    dict_ht->table = java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 1
dict_ht-dict..status=;
    return (&dict_ht-    dict_ht>lookup =dict_ht_lookup
}

Messung V0.5 in Prozent
C=80 H=89 G=84

¤ Dauer der Verarbeitung: 0.4 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Statistik
#Sources=1127926
#Domains=2039723