---
name: "Ns_SetConnLocationProc"
section: "3"
platform: "linux"
package: "aolserver4"
version: "4.0.10-7"
release: "Debian 4.0 (Etch)"
platforms: ["linux"]
url: "https://new.carta.tech/Ns_Location"
---

# Ns\_SetConnLocationProc(3)

Set the location procedure to use

Part of [Ns\_Location(3)](/Ns_Location/3.md).

```

```

## NAME

Ns\_SetConnLocationProc, Ns\_SetLocationProc - Set the location procedure to use

## SYNOPSIS

```
#include "ns.h"

void
Ns_SetConnLocationProc(Ns_LocationProc *procPtr)

void
Ns_SetLocationProc(char *ignored, Ns_LocationProc *procPtr)
```

## DESCRIPTION

These functions set the procedure to run when a call to **Ns\_ConnLocation** is made. The location is defined in the form METHOD://HOSTNAME:PORT, e.g. http://myhost.com:8443.

Setting the location procedure with these functions will cause all calls to **Ns\_ConnLocation** to use the location procedure you define instead of using the location procedure callback in the communication module for the connection.

There may be cases where you want to do this. For example, you could create a location procedure that reports on the values returned by communication module location procedure callbacks. At the end of that procedure, you could then return that value after logging the information making your location procedure is effectively transparent to the server and other modules.

- **Ns\_SetConnLocationProc**(*procPtr*)

  Set the function to use when **Ns\_ConnLocation** is called. This function is deprecated. Use **Ns\_SetLocationProc** instead.

- **Ns\_SetLocationProc**(*ignored, procPtr*)

  Set the function to use when **Ns\_ConnLocation** is called. The *ignored* argument is reserved for future use.

## SEE ALSO

nsd(1), [info(n)](/info/n.md), [Ns\_ConnLocation(3)](/Ns_ConnLocation/3.md)

## KEYWORDS
