Set a data server variable
#include <ds.h> int ds_set( ds_t dsdes, const char* variable_name, const char* variable_data, size_t data_len );
libds
Use the -l ds option to qcc to link against this library.
The ds_set() function passes the data variable_data to the data server identified by dsdes. The data server stores the data in the variable whose name is given by variable_name, overwriting any existing value.
To display the modified data on an HTML page, use the qnxvar token with the read tag. See the description of slinger in the Utilities Reference.
0 for success, or -1 if an error occurs (errno is set).
See slinger in the Utilities Reference.
Safety: | |
---|---|
Cancellation point | Yes |
Interrupt handler | No |
Signal handler | Yes |
Thread | Yes |
ds_create(), ds_flags(), ds_get()