2 ==================================================================================
3 Copyright (c) 2019 Nokia
4 Copyright (c) 2018-2019 AT&T Intellectual Property.
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
10 http://www.apache.org/licenses/LICENSE-2.0
12 Unless required by applicable law or agreed to in writing, software
13 distributed under the License is distributed on an "AS IS" BASIS,
14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 See the License for the specific language governing permissions and
16 limitations under the License.
17 ==================================================================================
21 Mnemonic rmr_init_trace_man.xfm
22 Abstract The manual page for the rmr_init_trace function.
23 Author E. Scott Daniels
28 .im &{lib}/man/setup.im
32 &h1(RMR Library Functions)
41 void* rmr_init_trace( void* ctx )
47 The &cw(rmr_init_trace) function establishes the default trace space placed in each
48 message buffer allocated with &cw(rmr_alloc_msg().)
49 If this function is never called, then no trace space is allocated by default into
53 Trace space allows the user application to pass some trace token, or other data
54 with the message, but outside of the payload.
55 Trace data may be added to any message with &cw(rmr_set_trace(),) and may be extracted
56 from a message with &cw(rmr_get_trace().)
57 The number of bytes that a message contains for/with trace data can be determined by
58 invoking &cw(rmr_get_trlen().)
61 This function may be safely called at any time during the life of the user programme
62 to (re)set the default trace space reserved.
63 If the user programme needs to allocate a message with trace space of a different
64 size than is allocated by default, without fear of extra overhead of reallocating
65 a message later, the &cw(rmr_tralloc_msg()) function can be used.
68 A value of 1 is returned on success, and 0 on failure. A failure indicates that the
69 RMr context (a void pointer passed to this function was not valid.