1SSAOidCmp(3SNMP)            SNMP Library Functions            SSAOidCmp(3SNMP)
2
3
4

NAME

6       SSAOidCmp,  SSAOidCpy,  SSAOidDup,  SSAOidFree,  SSAOidInit, SSAOidNew,
7       SSAOidString, SSAOidStrToOid,  SSAOidZero  -  Sun  Solstice  Enterprise
8       Agent OID helper functions
9

SYNOPSIS

11       cc [ flag ... ] file ... -lssasnmp [ library .. ]
12       #include <impl.h>
13
14
15
16       int SSAOidCmp(Oid *oid1, Oid *oid2);
17
18
19       int SSAOidCpy(Oid *oid1, Oid *oid2, char *error_label);
20
21
22       Oid *SSAOidDup(Oid *oid, char *error_label);
23
24
25       void SSAOidFree(Oid *oid);
26
27
28       int SSAOidInit(Oid *oid, Subid *subids, int len, char *error_label);
29
30
31       Oid *SSAOidNew();
32
33
34       char *SSAOidString(Oid *oid);
35
36
37       Oid *SSAOidStrToOid(char* name, char *error_label);
38
39
40       void SSAOidZero(Oid *oid);
41
42

DESCRIPTION

44       The  SSAOidCmp() function performs a comparison of the given OIDs. This
45       function returns:
46
47       0        if oid1 is equal to oid2
48
49
50       1        if oid1 is greater than oid2
51
52
53       −1       if oid1 is less than oid2
54
55
56
57       The SSAOidCpy() function makes a deep copy of oid2 to oid1. This  func‐
58       tion   assumes  oid1  has  been processed by the SSAOidZero() function.
59       Memory is allocated inside oid1 and the contents of oid2, not just  the
60       pointer,  is  copied to oid1. If an error is encountered, an error mes‐
61       sage is stored in the error_label buffer.
62
63
64       The SSAOidDup() function returns a clone of  oid,  by  using  the  deep
65       copy. Error information is stored in the error_label buffer.
66
67
68       The SSAOidFree() function frees the OID instance, with its content.
69
70
71       The SSAOidNew() function returns a new OID.
72
73
74       The SSAOidInit() function copies the Subid array from subids to the OID
75       instance with the specified length len. This function assumes that  the
76       OID instance has been processed by the SSAOidZero() function or no mem‐
77       ory is allocated inside the OID instance. If an error  is  encountered,
78       an error message is stored in the error_label buffer.
79
80
81       The  SSAOidString()  function  returns a char pointer for the printable
82       form of the given oid.
83
84
85       The SSAOidStrToOid() function returns a new OID instance from name.  If
86       an  error is encountered, an error message is stored in the error_label
87       buffer.
88
89
90       The SSAOidZero() function frees the memory used by the OID  object  for
91       buffers, but not the OID instance itself.
92

RETURN VALUES

94       The  SSAOidNew() and SSAOidStrToOid() functions return 0 if an error is
95       detected.
96

ATTRIBUTES

98       See attributes(5) for descriptions of the following attributes:
99
100
101
102
103       ┌─────────────────────────────┬─────────────────────────────┐
104       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
105       ├─────────────────────────────┼─────────────────────────────┤
106       │Interface Stability          │Obsolete                     │
107       ├─────────────────────────────┼─────────────────────────────┤
108       │MT-Level                     │Unsafe                       │
109       └─────────────────────────────┴─────────────────────────────┘
110

SEE ALSO

112       attributes(5)
113
114
115
116SunOS 5.11                        30 Apr 2006                 SSAOidCmp(3SNMP)
Impressum