Skip to content

ttysnoop.bt does not run properly #12

@gtataranni

Description

@gtataranni

When run as bpftrace ttysnoop.bt pts2 it returns

$1 used numerically, but given "pts2". Try using str($1).

I have tried to look into str($1 + 3) with printf("arg+3 is %s\n", str($1 + 3)); with an exit right after. I wasn't able unfortunately to get my argument string as expected, or the argument from the 3rd char on, I would only get arg+3 is .
Interestingly, the BCC counterpart works

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions