OpenSLP Programmers Guide - SLPFindScopes()

## SLPFindScopes

### Declaration

`#include <slp.h>`

`SLPError SLPFindScopes( SLPHandle hslp,`
`char** scopelist )`

### Description

Sets the scopelist parameter to a pointer to a comma separated list of all available scope values. The most desirable values are always placed first in the list. There is always one value, "DEFAULT", in the list.

### Parameters

`hslp` | Pointer to the string to be un-escaped
`scopelist` | Pointer to a pointer for the dynamically allocated list of scopes. The memory should be freed by a call to `SLPFree()` when no longer needed.

### Returns

SLP_OK | Indicates that the no error occurred during the operation.
SLP_NETWORK_TIMED_OUT | When no reply can be obtained in the time specified by the configured timeout interval for a unicast request, this error is returned. In other words, slpd is running, but something is wrong with it
SLP_NETWORK_INIT_FAILED | If the network cannot initialize properly, this error is returned. Will also be returned if an SA or DA agent (slpd) can not be contacted. slpd must be running in order to call SLPReg() or SLPDereg().
SLP_MEMORY_ALLOC_FAILED | Out of memory error
SLP_NETWORK_ERROR | The failure of networking during normal operations causes this error to be returned. In OpenSLP, this is the error you'll get if an underlying socket() call failed.
SLP_INTERNAL_SYSTEM_ERROR | A basic failure of the API causes this error to be returned. This occurs when a system call or library fails. The operation could not recover.

### Status

OpenSLP 0.8.0 | Fully implemented as specified by RFC 2608.

### See Also

Open SLP Users Guide