---
name: "pcap_minor_version"
section: "3pcap"
platform: "linux"
package: "libpcap"
version: "1.11.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/pcap_major_version/3pcap"
---

# pcap\_minor\_version(3pcap)

get the version number of a savefile

Part of [pcap\_major\_version(3pcap)](/pcap_major_version/3pcap.md).

## NAME

pcap\_major\_version, pcap\_minor\_version - get the version number of a savefile

## SYNOPSIS

```
#include <pcap/pcap.h>
```

**int pcap\_major\_version(pcap\_t \*p);** **int pcap\_minor\_version(pcap\_t \*p);**

## DESCRIPTION

If *p* refers to a \`\`savefile'', **pcap\_major\_version**() returns the major number of the file format of the \`\`savefile'' and **pcap\_minor\_version**() returns the minor number of the file format of the \`\`savefile''.  The version number is stored in the \`\`savefile''; note that the meaning of its values depends on the type of \`\`savefile'' (for example, pcap or pcapng).

If *p* refers to a live capture, the values returned by **pcap\_major\_version**() and **pcap\_minor\_version**() are not meaningful.

## SEE ALSO

**pcap**(3PCAP)
