Skip to content

Crasher in Pion when logging at DEBUG or TRACE level. ICE Candidate Pair String() #197

@tomandersen

Description

@tomandersen

Your environment.

Version:
github.com/pion/rtp v1.5.5
github.com/pion/webrtc/v2 v2.2.15

Browser: N/A

Other Information -

What did you do?

Turned on debug logging at the TRACE level.
ENV setting:
PION_LOG_TRACE=all

What did you expect?

For the program to run as before, only with logging.

What happened?

When the connection was shutdown by the remote side, the logger crashed Pion.

It looks like the String() function in the candidatepair.go file assumes that 'p' will not be nil. But I think one part went away as the remote connection died.

Screen Shot 2020-06-15 at 4 02 53 PM

There is other code that checks whether p is nil before continuing in that same file. Seems an easy fix.

--Tom

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions