| Tor 0.4.9.3-alpha-dev
    | 
Top-level declarations for the smartlist_t dynamic array type. More...
#include <stddef.h>#include "lib/cc/compat_compiler.h"#include "lib/cc/torint.h"#include "lib/testsupport/testsupport.h"Go to the source code of this file.
| Data Structures | |
| struct | unglob_fn | 
| Macros | |
| #define | smartlist_free(sl) FREE_AND_NULL(smartlist_t, smartlist_free_, (sl)) | 
| #define | smartlist_len(sl) ((sl)->num_used) | 
| #define | smartlist_get(sl, idx) ((sl)->list[idx]) | 
| #define | smartlist_set(sl, idx, val) ((sl)->list[idx] = (val)) | 
| Functions | |
| smartlist_t * | smartlist_new (void) | 
| void | smartlist_free_ (smartlist_t *sl) | 
| void | smartlist_clear (smartlist_t *sl) | 
| void | smartlist_add (smartlist_t *sl, void *element) | 
| void | smartlist_add_all (smartlist_t *sl, const smartlist_t *s2) | 
| void | smartlist_add_strdup (struct smartlist_t *sl, const char *string) | 
| void | smartlist_grow (smartlist_t *sl, size_t new_size) | 
| void | smartlist_remove (smartlist_t *sl, const void *element) | 
| void | smartlist_remove_keeporder (smartlist_t *sl, const void *element) | 
| void * | smartlist_pop_last (smartlist_t *sl) | 
| int | smartlist_contains (const smartlist_t *sl, const void *element) | 
| static void | smartlist_swap (smartlist_t *sl, int idx1, int idx2) | 
| void | smartlist_del (smartlist_t *sl, int idx) | 
| void | smartlist_del_keeporder (smartlist_t *sl, int idx) | 
| void | smartlist_insert (smartlist_t *sl, int idx, void *val) | 
Top-level declarations for the smartlist_t dynamic array type.
Definition in file smartlist_core.h.
| #define smartlist_free | ( | sl | ) | FREE_AND_NULL(smartlist_t, smartlist_free_, (sl)) | 
Definition at line 40 of file smartlist_core.h.
| #define smartlist_get | ( | sl, | |
| idx | |||
| ) | ((sl)->list[idx]) | 
Definition at line 82 of file smartlist_core.h.
| #define smartlist_len | ( | sl | ) | ((sl)->num_used) | 
Definition at line 81 of file smartlist_core.h.
| #define smartlist_set | ( | sl, | |
| idx, | |||
| val | |||
| ) | ((sl)->list[idx] = (val)) | 
Definition at line 83 of file smartlist_core.h.
| void smartlist_add | ( | smartlist_t * | sl, | 
| void * | element | ||
| ) | 
Append element to the end of the list.
Definition at line 117 of file smartlist_core.c.
Referenced by accept_encoding_header(), add_connection_to_closeable_list(), add_non_glob_path(), add_predicted_port(), addr_policy_append_reject_addr(), apply_ed_diff(), authdir_type_to_string(), authority_cert_get_all(), authority_certs_fetch_missing(), bridge_add_from_config(), build_desc_intro_points(), build_service_desc_superencrypted(), build_vanguard_middle_exclude_list(), cfx_add_leg(), channel_change_state_(), channel_flush_from_first_active_circuit(), channel_listener_change_state(), channel_listener_queue_incoming(), channel_listener_register(), channel_register(), channel_rsa_id_group_set_badness(), check_family_certs(), choose_good_exit_server_general(), circuit_add_to_origin_circuit_list(), circuit_describe_status_for_controller(), circuit_get_all_pending_on_channel(), circuit_list_path_impl(), circuit_log_ancient_one_hop_circuits(), circuit_mark_for_close_(), circuit_set_state(), circuit_unlink_all_from_channel(), circuitmux_detach_all_circuits(), cleanup_intro_points(), client_check_address_changed(), compute_consensus_package_lines(), compute_frac_paths_available(), compute_nth_protocol_set(), compute_routerstatus_consensus(), config_generic_service(), config_mgr_add_format(), config_mgr_list_deprecated_vars(), config_mgr_list_vars(), config_mgr_register_fmt(), config_new(), config_service(), conflux_add_guards_to_exclude_list(), conflux_add_middles_to_exclude_list(), conflux_mark_all_for_close(), connection_add_impl(), connection_ap_attach_pending(), connection_ap_mark_as_pending_circuit_(), connection_or_report_broken_states(), connection_start_reading_from_linked_conn(), consdiffmgr_rescan_flavor_(), consensus_cache_add(), consensus_cache_find_all(), consensus_cache_rescan(), consensus_split_lines(), control_event_descriptors_changed(), control_event_networkstatus_changed_helper(), control_event_networkstatus_changed_single(), control_reply_add_one_kv(), controller_get_routerdescs(), count_usable_descriptors(), crypto_write_tagged_contents_to_file(), dcfg_add_recv(), decode_hashed_passwords(), decode_intro_points(), decode_link_specifiers(), desc_decode_superencrypted_v3(), dir_server_add(), dir_split_resource_into_fingerprint_pairs(), dir_split_resource_into_spoolable(), dircollator_collate_by_ed25519(), directory_get_consensus_url(), dirserv_add_descriptor(), dirserv_generate_networkstatus_vote_obj(), dirserv_get_routerdesc_spool(), dirvote_add_vote(), dirvote_compute_consensuses(), dirvote_compute_params(), dirvote_fetch_missing_votes(), dirvote_format_all_microdesc_vote_lines(), dump_desc_fifo_add_and_clean(), dump_desc_fifo_bump_hash(), dump_desc_populate_fifo_from_directory(), enqueue_timestamp(), entry_connection_describe_status_for_controller(), entry_guard_add_to_sample_impl(), entry_guards_load_guards_from_state(), entry_guards_update_confirmed(), entry_guards_update_primary(), entry_guards_upgrade_waiting_circuits(), extract_shared_random_commits(), extrainfo_dump_to_string_header_helper(), extrainfo_dump_to_string_stats_helper(), find_all_exitpolicy(), first_reachable_filtered_entry_guard(), format_networkstatus_vote(), gen_ed_diff(), geoip_add_entry(), geoip_get_client_history(), geoip_get_request_history(), get_all_auth_client_lines(), get_all_possible_sybil(), get_authmethods(), get_detached_signatures_from_pending_consensuses(), get_eligible_guards(), get_frequent_members(), get_glob_paths(), get_guard_selection_by_name(), get_inner_encrypted_layer_plaintext(), get_interface_address6_list(), get_majority_srv_from_votes(), get_my_declared_family(), get_ns_str_from_sr_values(), get_outer_encrypted_layer_plaintext(), getinfo_helper_dir(), getinfo_helper_entry_guards(), getinfo_helper_listeners(), getinfo_helper_misc(), getinfo_helper_networkstatus(), guards_choose_guard(), handle_control_add_onion(), handle_control_extendcircuit(), handle_control_hsfetch(), handle_control_hspost(), handle_control_onion_client_auth_view(), handle_control_resolve(), handle_get_current_consensus(), handle_get_keys(), hs_cell_parse_introduce2(), hs_circuitmap_get_all_intro_circ_relay_side(), hs_get_responsible_hsdirs(), hs_pick_hsdir(), hs_service_add_ephemeral(), hs_service_get_metrics_stores(), hs_set_conn_addr_port(), init_circuit_base(), init_geoip_countries(), initiate_descriptor_downloads(), list_authority_ids_with_downloads(), list_bridge_identities(), list_sk_digests_for_authority_id(), list_v3_auth_ids(), load_client_keys(), load_family_id_keys_impl(), logfile_deliver(), logv(), maintain_layer2_guards(), make_guard_confirmed(), managed_proxy_create(), metrics_parse_ports(), metrics_store_add(), metrics_store_entry_add_label(), microdesc_cache_rebuild(), microdesc_list_missing_digest256(), microdescs_add_list_to_cache(), microdescs_parse_from_string(), namemap_get_or_create_id(), networkstatus_add_detached_signatures(), networkstatus_check_consensus_signature(), networkstatus_compute_consensus(), networkstatus_get_detached_signatures(), networkstatus_getinfo_by_purpose(), networkstatus_parse_detached_signatures(), networkstatus_parse_vote_from_string(), node_get_by_nickname(), node_get_or_create(), node_lookup_declared_family_list(), nodefamily_add_nodes_to_smartlist(), nodelist_add_node_and_family(), nodelist_find_nodes_with_microdesc(), notify_control_networkstatus_changed(), ob_option_parse(), options_validate_cb(), options_validate_relay_mode(), parse_addr_policy(), parse_bridge_line(), parse_consensus_request(), parse_dir_authority_line(), parse_dir_fallback_line(), parse_from_state_set_vals(), parse_method_line_helper(), parse_or_diff_from_header(), parse_protocol_list(), periodic_events_register(), pick_intro_point(), pick_needed_intro_points(), pick_oos_victims(), pick_restricted_middle_node(), policies_copy_addr_to_smartlist(), policy_dump_to_string(), policy_expand_private(), policy_expand_unspec(), policy_summary_create(), port_parse_config(), process_append_argument(), process_new(), process_reset_environment(), protover_all_supported(), protover_compute_vote(), pt_stringify_socks_args(), pubsub_add_pub_(), pubsub_add_sub_(), pubsub_adjmap_add(), pubsub_connector_register_type_(), queue_control_event_string(), queued_events_flush_all(), relay_metrics_get_stores(), relay_send_command_from_edge_(), rep_hist_add_buffer_stats(), rep_hist_get_predicted_ports(), rep_hist_log_link_protocol_counts(), resolved_cell_parse(), retry_all_listeners(), retry_listener_ports(), router_add_exit_policy(), router_add_running_nodes_to_smartlist(), router_dump_router_to_string(), router_get_descriptor_digests_in_consensus(), router_load_routers_from_string(), router_load_single_router(), router_parse_list_from_string(), router_pick_directory_server_impl(), router_pick_trusteddirserver_impl(), router_rebuild_store(), routerlist_insert(), routerlist_insert_old(), routerlist_remove(), routerlist_replace(), routerset_parse(), select_primary_guard_for_circuit(), service_add_fnames_to_list(), service_authorized_client_config_equal(), set_environment_variable_in_smartlist(), setup_desc_intro_point(), setup_intro_point_exclude_list(), smartlist_add_linecpy(), smartlist_add_strdup(), smartlist_add_vasprintf(), smartlist_insert(), smartlist_pqueue_add(), smartlist_split_string(), sr_compute_srv(), sr_get_string_for_vote(), storage_dir_save_bytes_to_file(), storage_dir_save_chunks_to_file(), storage_dir_save_labeled_to_file(), tokenize_string(), tor_glob(), tor_mainloop_connect_pubsub_events(), transport_add(), trusted_dir_server_add_dirport(), trusted_dirs_load_certs_from_string(), unlinked_close_all_legs(), unlinked_leg_add(), update_consensus_router_descriptor_downloads(), and update_extrainfo_downloads().
| void smartlist_add_all | ( | smartlist_t * | s1, | 
| const smartlist_t * | s2 | ||
| ) | 
Append each element from S2 to the end of S1.
Definition at line 125 of file smartlist_core.c.
Referenced by client_get_random_intro(), compute_consensus_method(), consdiff_gen_diff(), dir_split_resource_into_fingerprint_pairs(), dir_split_resource_into_fingerprints(), directory_remove_invalid(), dirserv_generate_networkstatus_vote_obj(), dirvote_clear_votes(), dirvote_compute_params(), entry_guards_update_primary(), format_recommended_version_list(), gen_ed_diff(), get_glob_paths(), get_sybil_list_by_ip_version(), handle_control_authenticate(), hs_service_stage_services(), lint_message_consistency(), networkstatus_compute_consensus(), parse_addr_policy(), parse_bridge_line(), port_parse_ports_relay(), process_environment_make(), pt_configure_remaining_proxies(), resolved_cell_parse(), retry_listener_ports(), router_choose_random_node(), routerset_parse(), sr_get_string_for_vote(), and unglob_opened_files().
| void smartlist_add_strdup | ( | struct smartlist_t * | sl, | 
| const char * | string | ||
| ) | 
Append a copy of string to sl
Definition at line 137 of file smartlist_core.c.
Referenced by add_transport_to_proxy(), add_wildcarded_test_address(), authority_certs_fetch_missing(), consensus_queue_compression_work(), control_event_networkstatus_changed_helper(), create_managed_proxy_environment(), dirserv_generate_networkstatus_vote_obj(), dirserv_read_measured_bandwidths(), dirvote_add_signatures(), encode_protocol_list(), entry_guard_encode_for_state(), extrainfo_dump_to_string(), extrainfo_dump_to_string_ed_sig_helper(), extrainfo_dump_to_string_rsa_sig_helper(), extrainfo_dump_to_string_stats_helper(), format_networkstatus_vote(), geoip_get_transport_history(), get_current_process_environment_variables(), get_my_declared_family(), get_options_from_transport_options_line(), hs_service_lists_fnames_for_sandbox(), list_family_key_files(), microdesc_note_outdated_dirserver(), networkstatus_compute_consensus(), networkstatus_format_signatures(), networkstatus_parse_vote_from_string(), nodefamily_format(), nodefamily_from_members(), options_init_logs(), policy_summarize(), router_dump_router_to_string(), router_parse_entry_from_string(), routerset_add_unknown_ccs(), routerstatus_format_entry(), service_desc_note_upload(), tor_listdir(), tor_log_get_logfile_names(), wildcard_increment_answer(), and write_short_policy().
| void smartlist_clear | ( | smartlist_t * | sl | ) | 
Remove all elements from the list.
Definition at line 50 of file smartlist_core.c.
Referenced by channel_rsa_id_group_set_badness(), choose_good_exit_server_general(), circuit_close_all_marked(), clear_bridge_list(), clear_dir_servers(), clear_transport_list(), client_check_address_changed(), compute_consensus_method(), compute_consensus_package_lines(), config_register_addressmaps(), consdiffmgr_cleanup(), consdiffmgr_consensus_load(), control_reply_clear(), dirserv_add_multiple_descriptors(), dirvote_clear_votes(), dirvote_compute_consensuses(), dns_reset_correctness_checks(), entry_guards_update_confirmed(), extract_shared_random_commits(), flush_pending_log_callbacks(), hs_descriptor_clear_intro_points(), microdesc_reset_outdated_dirservers_list(), microdescs_add_list_to_cache(), networkstatus_compute_consensus(), options_init_logs(), parse_addr_policy(), parse_bridge_line(), port_parse_config(), proxy_prepare_for_restart(), pt_prepare_proxy_list_for_config_read(), purge_vanguards_lite(), register_all_services(), rep_hist_reset_buffer_stats(), router_load_routers_from_string(), router_reset_warnings(), routerlist_reset_warnings(), and service_desc_clear_previous_hsdirs().
| int smartlist_contains | ( | const smartlist_t * | sl, | 
| const void * | element | ||
| ) | 
Return true iff some element E of sl has E==element.
Definition at line 201 of file smartlist_core.c.
Referenced by add_connection_to_closeable_list(), assert_circuit_ok(), config_mgr_register_fmt(), connection_ap_attach_pending(), connection_ap_mark_as_pending_circuit_(), connection_ap_rescan_and_attach_pending(), connection_in_array(), connection_is_on_closeable_list(), connection_start_reading_from_linked_conn(), connection_stop_reading_from_linked_conn(), entry_guards_update_primary(), hs_get_responsible_hsdirs(), make_guard_confirmed(), periodic_events_register(), remove_guard_from_confirmed_and_primary_lists(), smartlist_intersect(), and smartlist_overlap().
| void smartlist_del | ( | smartlist_t * | sl, | 
| int | idx | ||
| ) | 
Remove the idxth element of sl; if idx is not the last element, swap the last element of sl into the idxth space.
Definition at line 214 of file smartlist_core.c.
Referenced by circuit_close_all_marked(), circuit_free_(), circuit_remove_from_origin_circuit_list(), circuit_remove_handled_ports(), client_get_random_intro(), connection_remove(), consdiffmgr_rescan_flavor_(), handle_control_del_onion(), nodelist_drop_node(), preprocess_consensus(), routerlist_insert(), routerlist_remove(), and routerlist_remove_old().
| void smartlist_del_keeporder | ( | smartlist_t * | sl, | 
| int | idx | ||
| ) | 
Remove the idxth element of sl; if idx is not the last element, moving all subsequent elements back one space. Return the old value of the idxth element.
Definition at line 228 of file smartlist_core.c.
Referenced by connection_half_edge_is_valid_end(), dequeue_timestamp(), dir_split_resource_into_fingerprints(), dump_desc_fifo_add_and_clean(), exit_policy_remove_redundancies(), extrainfo_dump_to_string(), parse_bridge_line(), parse_dir_authority_line(), pt_parse_transport_line(), remove_duplicate_orports(), remove_flag(), and smartlist_uniq().
| void smartlist_free_ | ( | smartlist_t * | sl | ) | 
Deallocate a smartlist. Does not release storage associated with the list's elements.
Definition at line 39 of file smartlist_core.c.
Referenced by control_reply_free_().
| void smartlist_grow | ( | smartlist_t * | sl, | 
| size_t | new_size | ||
| ) | 
Expand sl so that its length is at least new_size, filling in previously unused entries with NULL>
Do nothing if sl already had at least new_size elements.
Definition at line 97 of file smartlist_core.c.
Referenced by dcfg_add_recv(), dcfg_msg_set_chan(), dcfg_msg_set_type(), and dcfg_type_set_fns().
| void smartlist_insert | ( | smartlist_t * | sl, | 
| int | idx, | ||
| void * | val | ||
| ) | 
Insert the value val as the new idxth element of sl, moving all items previously at idx or later forward one space.
Definition at line 244 of file smartlist_core.c.
Referenced by connection_half_edge_add(), and policy_summary_split().
| smartlist_t * smartlist_new | ( | void | ) | 
Allocate and return an empty smartlist.
Definition at line 26 of file smartlist_core.c.
Referenced by accept_encoding_header(), accounting_parse_options(), add_onion_helper_keyarg(), add_wildcarded_test_address(), addr_policy_append_reject_addr(), append_cell_stats_by_command(), apply_ed_diff(), authdir_type_to_string(), authority_cert_parse_from_string(), authority_certs_fetch_missing(), bridge_add_from_config(), bridge_list_get(), build_middle_exclude_list(), build_service_desc_encrypted(), build_service_desc_superencrypted(), build_vanguard_middle_exclude_list(), bwhist_update_bwhist_state_section(), cdm_cache_lookup_consensus(), channel_change_state_(), channel_flush_from_first_active_circuit(), channel_listener_change_state(), channel_listener_queue_incoming(), channel_listener_register(), channel_register(), channel_rsa_id_group_set_badness(), check_family_certs(), choose_good_entry_server(), choose_good_exit_server_general(), choose_good_middle_server(), circpad_machines_init(), circuit_build_times_parse_state(), circuit_count_pending_on_channel(), circuit_describe_status_for_controller(), circuit_find_circuits_to_upgrade_from_guard_wait(), circuit_get_global_list(), circuit_get_global_origin_circuit_list(), circuit_list_path_impl(), circuit_log_ancient_one_hop_circuits(), circuit_mark_for_close_(), circuit_n_chan_done(), circuit_set_state(), circuit_unlink_all_from_channel(), cleanup_intro_points(), clear_bridge_list(), clear_dir_servers(), clear_transport_list(), client_check_address_changed(), client_get_random_intro(), client_likes_consensus(), compute_consensus_method(), compute_consensus_package_lines(), compute_consensus_versions_list(), compute_frac_paths_available(), compute_nth_protocol_set(), compute_routerstatus_consensus(), config_dump(), config_mgr_list_deprecated_vars(), config_mgr_list_vars(), config_mgr_new(), config_register_addressmaps(), config_suite_new(), conflux_mark_all_for_close(), conflux_new(), congestion_control_init(), connection_ap_attach_pending(), connection_ap_mark_as_pending_circuit_(), connection_ap_rescan_and_attach_pending(), connection_dir_bridge_routerdesc_failed(), connection_dir_download_cert_failed(), connection_edge_process_resolved_cell(), connection_half_edge_add(), connection_or_report_broken_states(), consdiff_gen_diff(), consdiff_get_digests(), consdiffmgr_cleanup(), consdiffmgr_consensus_load(), consdiffmgr_diffs_load(), consdiffmgr_ensure_space_for_files(), consdiffmgr_find_diff_from(), consdiffmgr_rescan_flavor_(), consdiffmgr_set_cache_flags(), consdiffmgr_validate(), consensus_cache_find_first(), consensus_cache_rescan(), consensus_diff_apply(), consensus_diff_generate(), consensus_queue_compression_work(), control_cmd_parse_args(), control_event_conf_changed(), control_event_descriptors_changed(), control_event_networkstatus_changed_helper(), control_event_networkstatus_changed_single(), control_ports_write_to_file(), controller_get_routerdescs(), create_initial_guard_context(), create_managed_proxy_environment(), crypto_write_tagged_contents_to_file(), dcfg_add_recv(), dcfg_new(), decode_auth_type(), decode_create2_list(), decode_hashed_passwords(), decode_intro_points(), decode_introduction_point(), decode_link_specifiers(), desc_decode_encrypted_v3(), desc_decode_superencrypted_v3(), desc_encode_v3(), dir_server_add(), dir_split_resource_into_fingerprint_pairs(), dir_split_resource_into_fingerprints(), dir_split_resource_into_spoolable(), dirauth_options_validate(), dirclient_dump_total_dls(), dircollator_collate(), directory_get_consensus_url(), directory_remove_invalid(), directory_send_command(), dirserv_add_descriptor(), dirserv_add_multiple_descriptors(), dirserv_generate_networkstatus_vote_obj(), dirvote_add_signatures(), dirvote_add_vote(), dirvote_clear_votes(), dirvote_compute_consensuses(), dirvote_compute_params(), dirvote_create_microdescriptor(), dirvote_fetch_missing_votes(), disk_state_parse_commits(), disk_state_parse_srv(), dump_desc_fifo_add_and_clean(), dump_desc_populate_fifo_from_directory(), encode_client_auth_cred_for_control_port(), encode_intro_point(), encode_protocol_list(), entry_connection_describe_status_for_controller(), entry_guard_chan_failed(), entry_guard_encode_for_state(), entry_guard_parse_from_state(), entry_guards_load_guards_from_state(), entry_guards_update_primary(), entry_guards_upgrade_waiting_circuits(), ewma_alloc_cmux_data(), extract_shared_random_commits(), extrainfo_dump_to_string(), extrainfo_parse_entry_from_string(), find_all_exitpolicy(), first_reachable_filtered_entry_guard(), flush_pending_log_callbacks(), format_cell_stats(), format_networkstatus_vote(), format_recommended_version_list(), gen_ed_diff(), geoip_get_client_history(), geoip_get_request_history(), geoip_get_transport_history(), geoip_load_file(), geoip_parse_entry(), get_all_auth_client_lines(), get_all_possible_sybil(), get_authmethods(), get_bindaddr_for_server_proxy(), get_bindaddr_from_transport_listen_line(), get_cert_list(), get_configured_ports(), get_connection_array(), get_current_family_id_keys(), get_current_process_environment_variables(), get_detached_signatures_from_pending_consensuses(), get_eligible_guards(), get_glob_paths(), get_guard_selection_by_name(), get_inner_encrypted_layer_plaintext(), get_interface_address6_list(), get_majority_srv_from_votes(), get_my_declared_family(), get_ns_str_from_sr_values(), get_options_from_transport_options_line(), get_outer_encrypted_layer_plaintext(), get_sybil_list_by_ip_version(), get_transport_in_state_by_name(), get_transport_options_for_server_proxy(), get_transport_proxy_ports(), getinfo_helper_config(), getinfo_helper_dir(), getinfo_helper_entry_guards(), getinfo_helper_events(), getinfo_helper_listeners(), getinfo_helper_misc(), getinfo_helper_networkstatus(), getinfo_helper_policies(), guard_selection_new(), handle_control_add_onion(), handle_control_authenticate(), handle_control_extendcircuit(), handle_control_getconf(), handle_control_getinfo(), handle_control_hsfetch(), handle_control_hspost(), handle_control_mapaddress(), handle_control_onion_client_auth_add(), handle_control_onion_client_auth_view(), handle_control_protocolinfo(), handle_control_resolve(), handle_get_current_consensus(), handle_get_descriptor(), handle_get_keys(), handle_get_microdesc(), handle_get_status_vote(), handle_response_fetch_desc(), handle_response_fetch_microdesc(), hs_circ_handle_introduce2(), hs_circuitmap_get_all_intro_circ_relay_side(), hs_config_service_all(), hs_control_hspost_command(), hs_desc_decode_plaintext(), hs_desc_intro_point_new(), hs_get_responsible_hsdirs(), hs_parse_port_config(), hs_pick_hsdir(), hs_service_add_ephemeral(), hs_service_get_metrics_stores(), hs_service_init(), hs_service_stage_services(), hs_set_conn_addr_port(), init_geoip_countries(), init_logging(), init_nodelist(), initialize_pow_defenses(), initiate_descriptor_downloads(), kvline_encode(), lint_message_consistency(), list_authority_ids_with_downloads(), list_bridge_identities(), list_family_key_files(), list_family_key_files_impl(), list_getinfo_options(), list_pending_downloads(), list_pending_fpsk_downloads(), list_sk_digests_for_authority_id(), list_v3_auth_ids(), load_client_keys(), load_family_id_keys_impl(), log_credential_status(), maintain_layer2_guards(), make_consensus_method_list(), managed_proxy_create(), mark_bridge_list(), mark_transport_list(), metrics_parse_ports(), metrics_store_add(), metrics_store_entry_new(), microdesc_cache_rebuild(), microdesc_list_missing_digest256(), microdesc_note_outdated_dirserver(), microdesc_parse_fields(), microdescs_add_list_to_cache(), microdescs_add_to_cache(), microdescs_parse_from_string(), namemap_get_or_create_id(), namemap_init(), networkstatus_check_consensus_signature(), networkstatus_compute_consensus(), networkstatus_format_signatures(), networkstatus_get_detached_signatures(), networkstatus_getinfo_by_purpose(), networkstatus_parse_detached_signatures(), networkstatus_parse_vote_from_string(), node_get_all_orports(), node_get_by_nickname(), nodefamily_canonicalize(), nodefamily_format(), nodelist_add_node_and_family(), nodelist_find_nodes_with_microdesc(), normalize_nickname_list(), notify_control_networkstatus_changed(), ob_option_parse(), options_init_from_string(), options_init_logs(), options_start_listener_transaction(), options_validate_cb(), options_validate_relay_mode(), parse_accept_encoding_header(), parse_addr_policy(), parse_auth_file_content(), parse_authorized_client(), parse_bridge_line(), parse_consensus_request(), parse_dir_authority_line(), parse_dir_fallback_line(), parse_http_response(), parse_log_severity_config(), parse_method_line_helper(), parse_or_diff_from_header(), parse_ports(), parse_private_key_from_control_port(), parse_protocol_list(), parse_tcp_proxy_line(), periodic_events_register(), pick_hsdir_v3(), pick_needed_intro_points(), pick_oos_victims(), pick_restricted_middle_node(), policies_parse_exit_policy_from_options(), policy_dump_to_string(), policy_expand_private(), policy_expand_unspec(), policy_summarize(), policy_summary_create(), port_parse_config(), port_parse_ports_relay(), predicted_ports_alloc(), process_environment_make(), process_init(), process_new(), process_reset_environment(), protover_all_supported(), protover_compute_vote(), pt_configure_remaining_proxies(), pt_get_extra_info_descriptor_string(), pt_parse_transport_line(), pt_stringify_socks_args(), pt_update_bridge_lines(), pubsub_adjmap_add(), pubsub_items_new(), queued_events_flush_all(), relay_metrics_get_stores(), relay_send_command_from_edge_(), rep_hist_add_buffer_stats(), rep_hist_format_buffer_stats(), rep_hist_format_exit_stats(), rep_hist_get_overload_stats_lines(), rep_hist_get_predicted_ports(), rep_hist_load_mtbf_data(), rep_hist_log_link_protocol_counts(), rep_hist_reset_buffer_stats(), resolved_cell_parse(), retry_all_listeners(), retry_listener_ports(), router_add_exit_policy(), router_choose_random_node(), router_dump_router_to_string(), router_get_descriptor_digests_in_consensus(), router_get_routerlist(), router_get_trusted_dir_servers_mutable(), router_load_extrainfo_from_string(), router_load_routers_from_string(), router_load_single_router(), router_parse_entry_from_string(), router_pick_directory_server_impl(), router_pick_trusteddirserver_impl(), router_rebuild_store(), routerlist_reset_warnings(), routerset_new(), routerset_parse(), routerstatus_format_entry(), select_primary_guard_for_circuit(), service_authorized_client_config_equal(), service_desc_hsdirs_changed(), service_descriptor_new(), set_expiry(), set_service_default_config(), sr_compute_srv(), sr_get_string_for_vote(), state_transport_line_is_valid(), storage_dir_save_bytes_to_file(), storage_dir_save_labeled_to_file(), string_is_valid_nonrfc_hostname(), sweep_bridge_list(), sweep_transport_list(), tor_glob(), tor_inet_aton(), tor_init_connection_lists(), tor_listdir(), tor_mainloop_connect_pubsub_events(), tor_version_is_obsolete(), transport_add(), trim_rend_pqueue(), trusted_dir_server_add_dirport(), trusted_dirs_flush_certs_to_disk(), unglob_opened_files(), unlinked_close_all_legs(), unlinked_new(), update_consensus_router_descriptor_downloads(), update_extrainfo_downloads(), upload_descriptor_to_all(), wildcard_increment_answer(), and write_short_policy().
| void * smartlist_pop_last | ( | smartlist_t * | sl | ) | 
If sl is nonempty, remove and return the final element. Otherwise, return NULL.
Definition at line 187 of file smartlist_core.c.
Referenced by connection_dirserv_flushed_some(), control_cmd_parse_args(), rend_pqueue_clear(), and string_is_valid_nonrfc_hostname().
| void smartlist_remove | ( | smartlist_t * | sl, | 
| const void * | element | ||
| ) | 
Remove all elements E from sl such that E==element. Preserve the order of any elements before E, but elements after E can be rearranged.
Definition at line 151 of file smartlist_core.c.
Referenced by cfx_del_leg(), channel_change_state_(), channel_listener_change_state(), channel_listener_unregister(), channel_unregister(), circuit_about_to_free(), circuit_set_state(), connection_ap_about_to_close(), connection_ap_mark_as_non_pending_circuit(), connection_stop_reading_from_linked_conn(), connection_unlink(), managed_proxy_destroy(), networkstatus_add_detached_signatures(), process_free_(), remove_all_entry_guards_for_guard_selection(), retry_listener_ports(), select_and_add_guard_item_for_sample(), smartlist_subtract(), and transport_resolve_conflicts().
| void smartlist_remove_keeporder | ( | smartlist_t * | sl, | 
| const void * | element | ||
| ) | 
As smartlist_remove, but do not change the order of any elements not removed
Definition at line 167 of file smartlist_core.c.
Referenced by remove_guard_from_confirmed_and_primary_lists().
| 
 | inlinestatic | 
Exchange the elements at indices idx1 and idx2 of the smartlist sl.
Definition at line 88 of file smartlist_core.h.
Referenced by smartlist_shuffle().