~ubuntu-branches/ubuntu/precise/net-snmp/precise

« back to all changes in this revision

Viewing changes to man/netsnmp_util.3

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2009-11-26 01:27:00 UTC
  • mfrom: (1.1.9 sid)
  • Revision ID: james.westby@ubuntu.com-20091126012700-pox7w0a5j2x305h9
Tags: 5.4.2.1~dfsg-3ubuntu1
* Merge from debian testing.  Remaining changes:
  - Set Ubuntu maintainer address.
  - net-snmp-config: Use bash. (LP: #104738)
  - Removed multiuser option when calling update-rc.d. (LP: #254261)
  - debian/snmpd.init: LSBify the init script.
  - debian/patches/52_fix_snmpcmd_1_typo.patch: Adjust a typo in snmpcmd.1
    (LP: #250459)
  - debian/patches/99-fix-ubuntu-div0.patch: Fix dvision by zero.
    (LP: #426813).
 * Dropped patches:
   - debian/patches/101-fix-ipalias.patch: Applied upstream.
   - debian/patches/99-fix-net-snmp-syslog.patch: Applied upstream.
   - debian/patches/99-fix-perl-counter-in-subagent.patch: Applied upstream.
   - ebian/patches/103-fix-ubuntu-lmsensors.patch: No longer needed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.TH "Memory Utility Routines" 3 "27 Jul 2007" "Version 5.4.1" "net-snmp" \" -*- nroff -*-
 
1
.TH "Memory Utility Routines" 3 "5 Sep 2008" "Version 5.4.2" "net-snmp" \" -*- nroff -*-
2
2
.ad l
3
3
.nh
4
4
.SH NAME
83
83
.br
84
84
.RI "\fIComputers the minimum of a and b. \fP"
85
85
.ti -1c
 
86
.RI "#define \fBSNMP_MACRO_VAL_TO_STR\fP(s)   SNMP_MACRO_VAL_TO_STR_PRIV(s)"
 
87
.br
 
88
.RI "\fIExpands to string with value of the s. \fP"
 
89
.ti -1c
 
90
.RI "#define \fBSNMP_MACRO_VAL_TO_STR_PRIV\fP(s)   #s"
 
91
.br
 
92
.ti -1c
86
93
.RI "#define \fBFALSE\fP   0"
87
94
.br
88
95
.ti -1c
221
228
\fBValue:\fP
222
229
.PP
223
230
.nf
224
 
{                                                    \
 
231
{                                                        \
225
232
        now.tv_sec--;                                   \
226
233
        now.tv_usec += 1000000L;                        \
227
234
        diff.tv_sec  = now.tv_sec  - then.tv_sec;       \
233
240
}
234
241
.fi
235
242
.PP
236
 
Definition at line 120 of file tools.h.
 
243
Definition at line 131 of file tools.h.
237
244
.SS "#define ISTRANSFORM(ttype, toid)"
238
245
.PP
239
246
\fBValue:\fP
243
250
                usm ## toid ## Protocol, USM_LENGTH_OID_TRANSFORM)
244
251
.fi
245
252
.PP
246
 
Definition at line 139 of file tools.h.
 
253
Definition at line 150 of file tools.h.
247
254
.SS "#define QUITFUN(e, l)"
248
255
.PP
249
256
\fBValue:\fP
255
262
        }
256
263
.fi
257
264
.PP
258
 
Definition at line 107 of file tools.h.
 
265
Definition at line 118 of file tools.h.
259
266
.SS "#define SNMP_FREE(s)   do { if (s) { free((void *)s); s=NULL; } } while(0)"
260
267
.PP
261
268
Frees a pointer only if it is !NULL and sets its value to NULL. 
263
270
Definition at line 53 of file tools.h.
264
271
.PP
265
272
Referenced by _sess_read(), build_oid_segment(), clear_callback(), clear_context(), clear_lookup_cache(), convert_v2pdu_to_v1(), create_user_from_session(), dump_chunk(), fprint_description(), fprint_objid(), fprint_value(), fprint_variable(), free_agent_snmp_session(), get_module_node(), get_node(), get_set_cache(), netsnmp_addrcache_add(), netsnmp_agent_check_packet(), netsnmp_agent_check_parse(), netsnmp_cache_reqinfo_extract(), netsnmp_cache_reqinfo_insert(), netsnmp_config_remember_free_list(), netsnmp_create_handler(), netsnmp_fixup_mib_directory(), netsnmp_free_agent_request_info(), netsnmp_free_all_list_data(), netsnmp_free_cachemap(), netsnmp_free_delegated_cache(), netsnmp_free_list_data(), netsnmp_getenv(), netsnmp_handler_free(), netsnmp_handler_registration_free(), netsnmp_init_mib(), netsnmp_iterator_delete_table(), netsnmp_reassign_requests(), netsnmp_register_agent_nsap(), netsnmp_register_old_api(), netsnmp_remove_loghandler(), netsnmp_row_merge_helper_handler(), netsnmp_sess_log_error(), netsnmp_set_mib_directory(), netsnmp_set_row_column(), netsnmp_sprint_realloc_objid(), netsnmp_sprint_realloc_objid_tree(), netsnmp_subtree_free(), netsnmp_subtree_join(), netsnmp_subtree_split(), netsnmp_table_build_oid_from_index(), netsnmp_table_data_delete_row(), netsnmp_table_data_delete_table(), netsnmp_table_data_set_helper_handler(), netsnmp_table_dataset_delete_data(), netsnmp_tcontainer_create_table(), netsnmp_tcontainer_delete_table(), netsnmp_tdata_clone_row(), netsnmp_tdata_delete_row(), netsnmp_tdata_delete_table(), netsnmp_wrap_up_request(), parse_octet_hint(), read_objid(), shutdown_mib(), snmp_add_var(), snmp_free_pdu(), snmp_free_var(), snmp_sess_close(), snmp_unregister_callback(), snmpv3_make_report(), snmpv3_parse(), table_helper_handler(), unregister_all_config_handlers(), unregister_config_handler(), and unregister_mibs_by_session().
 
273
.SS "#define SNMP_MACRO_VAL_TO_STR(s)   SNMP_MACRO_VAL_TO_STR_PRIV(s)"
 
274
.PP
 
275
Expands to string with value of the s. 
 
276
.PP
 
277
If s is macro, the resulting string is value of the macro. Example: define TEST 1234 \fBSNMP_MACRO_VAL_TO_STR(TEST)\fP expands to '1234' SNMP_MACRO_VAL_TO_STR(TEST+1) expands to '1234+1' 
 
278
.PP
 
279
Definition at line 99 of file tools.h.
266
280
.SS "#define SNMP_MALLOC_STRUCT(s)   (struct s *) calloc(1, sizeof(struct s))"
267
281
.PP
268
282
Mallocs memory of sizeof(struct s), zeros it and returns a pointer to it. 
290
304
.PP
291
305
Definition at line 89 of file tools.h.
292
306
.PP
293
 
Referenced by netsnmp_config_parse_table_set(), netsnmp_oid_find_prefix(), netsnmp_register_table_data_set(), netsnmp_scalar_group_helper_handler(), netsnmp_scalar_helper_handler(), netsnmp_stash_to_next_helper(), and netsnmp_table_data_helper_handler().
 
307
Referenced by netsnmp_config_parse_table_set(), netsnmp_oid_find_prefix(), netsnmp_register_table_data_set(), netsnmp_scalar_group_helper_handler(), netsnmp_scalar_helper_handler(), netsnmp_stash_to_next_helper(), netsnmp_table_data_helper_handler(), and sprint_realloc_octet_string().
294
308
.SS "#define SNMP_SWIPE_MEM(n, s)   do { if (n) free((void *)n); n = s; s=NULL; } while(0)"
295
309
.PP
296
310
Frees pointer n only if it is !NULL, sets n to s and sets s to NULL.