---
name: "sgetopt"
section: "3"
platform: "linux"
package: "qmail"
version: "1.06-6.2~deb10u1"
release: "Debian 10 (Buster)"
platforms: ["linux"]
url: "https://new.carta.tech/sgetopt"
---

# sgetopt(3)

get option character from command line

## NAME

sgetopt - get option character from command line

## SYNTAX

**#include \<sgetopt.h\>**

## DESCRIPTION

The **sgetopt** library is just like the **getopt** library, except that it prints errors using **substdio** rather than **stdio**.

See **[getopt(3)](/getopt/3.md)** for interface details.

## VERSION

sgetopt version 1.9, 931201.

## AUTHOR

Placed into the public domain by Daniel J. Bernstein.

## SEE ALSO

[getopt(3)](/getopt/3.md), [subgetopt(3)](/subgetopt/3.md), subfd(3), substdio(3)
