torture/t_asn1.c

ソースコードを見る。

関数

int main (void)

変数

static DATA_BLOB tests []
static int values []


関数

int main ( void   ) 

t_asn1.c27 行で定義されています。

参照先 asn1_load()asn1_read_Integer()asn1_write_Integer()data_blob_::datadata_blob_::lengthprintf()testspoptOption::valvalues.

00028 {
00029         int i = 0;
00030         int val;
00031         BOOL ok = True;
00032 
00033         for (i=0; tests[i].data != NULL; i++) {
00034                 ASN1_DATA data;
00035                 DATA_BLOB blob;
00036 
00037                 ZERO_STRUCT(data);
00038                 asn1_write_Integer(&data, values[i]);
00039 
00040                 if ((data.length != tests[i].length) ||
00041                     (memcmp(data.data, tests[i].data, data.length) != 0)) {
00042                         printf("Test for %d failed\n", values[i]);
00043                         ok = False;
00044                 }
00045 
00046                 blob.data = data.data;
00047                 blob.length = data.length;
00048                 asn1_load(&data, blob);
00049                 if (!asn1_read_Integer(&data, &val)) {
00050                         printf("Could not read our own Integer for %d\n",
00051                                values[i]);
00052                         ok = False;
00053                 }
00054                 if (val != values[i]) {
00055                         printf("%d -> ASN -> Int %d\n", values[i], val);
00056                         ok = False;
00057                 }
00058         }
00059 
00060         return ok ? 0 : 1;
00061 }


変数

DATA_BLOB tests[] [static]

初期値:

 {
        {"\x02\x01\x00", 3, NULL},
        {"\x02\x01\x7f", 3, NULL},
        {"\x02\x02\x00\x80", 4, NULL},
        {"\x02\x02\x01\x00", 4, NULL},
        {"\x02\x01\x80", 3, NULL},
        {"\x02\x02\xff\x7f", 4, NULL},
        {"\x02\x01\xff", 3, NULL},
        {"\x02\x02\xff\x01", 4, NULL},
        {"\x02\x02\x00\xff", 4, NULL},
        {"\x02\x04\x80\x00\x00\x00", 6, NULL},
        {"\x02\x04\x7f\xff\xff\xff", 6, NULL},
        {NULL, 0, NULL}
}

t_asn1.c9 行で定義されています。

参照元 main()test_strlcpy().

int values[] [static]

初期値:

 {0, 127, 128, 256, -128, -129, -1, -255, 255,
                       0x80000000, 0x7fffffff}

t_asn1.c24 行で定義されています。

参照元 _ntsvcs_get_device_reg_property()_reg_delete_value()_reg_set_value()add_new_svc_name()ads_dup_values()ads_mod_ber()ads_mod_str()ads_pull_guid()ads_pull_sd()ads_pull_sid()ads_pull_sids()ads_pull_string()ads_pull_strings()ads_pull_strvals()ads_pull_uint32()ads_push_strvals()ads_sasl_bind()convert_values_to_printer_info_2()copy_registry_tree()current_version()driver_arch_fetch_values()eventlog_add_source()eventlog_init_keys()fill_in_driver_values()fill_in_printer_values()fill_service_values()fill_svc_config()get_ldap_seq()get_value_information()init_registry_data()key_driver_fetch_values()key_forms_fetch_values()key_printers_fetch_values()key_printers_store_values()ldapsam_get_seq_num()main()reg_load_tree()reg_write_tree()regdb_fetch_values()regdb_pack_values()regdb_store_values()regdb_unpack_values()regfio_write_key()regprint_fetch_reg_values()regprint_store_reg_values()smbldap_check_root_dse()smbldap_get_single_attribute()smbldap_talloc_single_attribute()svcctl_fetch_regvalues()svcctl_get_secdesc()svcctl_lookup_description()svcctl_lookup_dispname()svcctl_set_secdesc()sync_eventlog_params()write_registry_tree().


Sambaに対してSat Aug 29 21:24:32 2009に生成されました。  doxygen 1.4.7