中间件,开发工具,实时操作系统软件和支持服务,助您完成卓越的嵌入式设计


Home
QNX Community Resources
QNX Documentation Library
resmgr_unbind

resmgr_unbind

QNX Software Systems
Developer Resources
Blogs
Board support packages
Foundry27 projects
Forums
Hardware support listing
Online video tutorials
Product documentation

resmgr_unbind()

Disassociate an OCB from an open request

Synopsis:

#include <sys/resmgr.h>

int resmgr_unbind( resmgr_context_t * ctp);

Arguments:

ctp
A pointer to a resmgr_context_t structure that the resource-manager library uses to pass context information between functions.

Library:

libc

Use the -l c option to qcc to link against this library. This library is usually included automatically.

Description:

The resmgr_unbind() function removes a binding in the internal resources manager database (which maps client connections to server OCB pointers). The binding must previously have been bound by resmgr_open_bind()

The binding is reference counted; if multiple connections are established with the same binding, the binding is freed only when the last connection is removed.

You should use MsgInfo() to fill the info structure in ctp with information about which client mapping to retrieve.

Returns:

-1
Failure.
0
Success.

Errors:

ESRCH
The binding can't be located in the resource manager table.

Classification:

QNX Neutrino

Safety:
Cancellation point No
Interrupt handler No
Signal handler No
Thread Yes

See also:

MsgInfo(), resmgr_context_t, resmgr_open_bind()

Writing a Resource Manager chapter of the Programmer's Guide