Product Documentation

c-treeDB API API for C

Previous Topic

Next Topic

ctdbGetSessionPath

Return the default session path.

Declaration

CTDBRET ctdbGetSessionPath(CTHANDLE Handle, pTEXT Path,

VRLEN PathSize)

Description

ctdbGetSessionPath() returns the session path that is stored in the session handle. Note that the returned session path will be empty unless you have previously called ctdbSetSessionPath() with that session handle. Use ctdbSetSessionPath() to set the session path.

  • Handle [in] the session handle.
  • Path [out] the pointer to a C string where the session path is returned.
  • PathSize [in] the Path size in bytes. If Path is not large enough to hold the session path, the error CTDBRET_ARGSMALL (4006) is returned.

Returns

ctdbGetSessionPath() returns CTDBRET_OK if successful, or the c-tree Plus error code on failure, or CTDBRET_ARGSMALL (4006) if the Path is not large enough to hold the session path.

Example


eRet = ctdbLogon(handle, "FAIRCOMS", "ADMIN", "ADMIN");

eRet = ctdbGetSessionPath(handle, ses_path, sizeof(ses_path));


See also

ctdbSetSessionPath()

TOCIndex