# github.com/pion/srtp/v2
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/session_srtp.go:144:9: assignment mismatch: 1 variable but h.Unmarshal returns 2 values
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp.go:37:9: assignment mismatch: 1 variable but header.Unmarshal returns 2 values
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp.go:52:9: assignment mismatch: 1 variable but header.Unmarshal returns 2 values
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp.go:56:51: header.PayloadOffset undefined (type *rtp.Header has no field or method PayloadOffset)
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp_cipher_aead_aes_gcm.go:99:13: header.PayloadOffset undefined (type *rtp.Header has no field or method PayloadOffset)
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp_cipher_aead_aes_gcm.go:104:18: header.PayloadOffset undefined (type *rtp.Header has no field or method PayloadOffset)
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp_cipher_aes_cm_hmac_sha1.go:121:30: header.PayloadOffset undefined (type *rtp.Header has no field or method PayloadOffset)
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/srtp_cipher_aes_cm_hmac_sha1.go:126:32: header.PayloadOffset undefined (type *rtp.Header has no field or method PayloadOffset)
../../../../1.16.2/pkg/mod/github.com/pion/srtp/v2@v2.0.2/stream_srtp.go:88:6: assignment mismatch: 1 variable but header.Unmarshal returns 2 values
While working on the one of my pet projects I caught the issue with building of my app. The fix is very easy but I spent some time to find out the issue and how to solve it.
So if you have the same issue you have to add to your go.mod file such line:
github.com/pion/srtp/v2 v2.0.5 // indirect
And update your packages with go mod. The problem was on this line – https://github.com/pion/srtp/compare/v2.0.4…v2.0.5#diff-42e63a61fe336233215c8623a90b1e1697a38e30aa9cafc1c396a9e37d61c00cR144