---
name: "function::sock_prot_str2num"
section: "3stap"
platform: "linux"
package: "systemtap-doc"
version: "5.1-5"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/function::sock_prot_str2num"
---

# function::sock\_prot\_str2num(3stap)

Given a protocol name (string), return the corresponding protocol number

## NAME

function::sock\_prot\_str2num - Given a protocol name (string), return the corresponding protocol number

## SYNOPSIS

```
    sock_prot_str2num:long(proto:string)
```

## ARGUMENTS

*proto*

The protocol name

## SEE ALSO0

[*tapset::socket*(3stap)](/tapset::socket/3stap.md)
