elf_ndxscn(3)

elf_ndxscn3

Retrieve the index of a descriptor for an elf file section

Usage

#include <libelf.h>

size_t elf_ndxscn(Elf_Scn *scn);

Overview

The elf_ndxscn function retrieves the index of the section descriptor referred to by scn.

Parameters

scn

An Elf_Scn pointer to the section descriptor whose index is to be retrieved.

Return value

The elf_ndxscn function returns the index of the section descriptor. If scn is NULL, it returns SHN_UNDEF. SHN_UNDEF is zero.

Attributes

For an explanation of the terms used in this section, see attributes(7).

InterfaceAttributeValue
elf_ndxscn()Thread safetyMT-Safe

Releases

Unchanged in 2 releases since Debian 13 (Trixie).

  1. 13–Arch

Reporting bugs

Report bugs to <[email protected]> or https://sourceware.org/bugzilla/.

From libelf 0.197-1 in Arch Linux 2026-11-01. Parsed by carta from the page's man source.