Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

irc: panic: runtime error: invalid memory address or nil pointer dereference #786

Closed
Bluscream opened this issue Apr 3, 2019 · 2 comments

Comments

@Bluscream
Copy link

Describe the bug

blu@minopia:~/go/bin $ ./matterbridge
[2019-04-03T01:04:44+02:00]  INFO main:         Running version 1.14.2-dev
[2019-04-03T01:04:44+02:00]  INFO main:         WARNING: THIS IS A DEVELOPMENT VERSION. Things may break.
[2019-04-03T01:04:44+02:00]  INFO router:       Parsing gateway Ayano
[2019-04-03T01:04:44+02:00]  INFO router:       Parsing gateway NyaNekoGame
[2019-04-03T01:04:44+02:00]  INFO router:       Starting bridge: irc.twitch
[2019-04-03T01:04:44+02:00]  INFO irc:          Connecting irc.chat.twitch.tv:6697
[2019-04-03T01:04:50+02:00]  INFO irc:          Connection succeeded
[2019-04-03T01:04:50+02:00]  INFO irc:          irc.twitch: joining #ayano_335 (ID: #ayano_335irc.twitch)
[2019-04-03T01:04:50+02:00]  INFO irc:          irc.twitch: joining #nyanekogame (ID: #nyanekogameirc.twitch)
[2019-04-03T01:04:50+02:00]  INFO router:       Starting bridge: discord.ayano
[2019-04-03T01:04:50+02:00]  INFO discord:      Connecting
[2019-04-03T01:04:50+02:00]  INFO discord:      Connecting using token
[2019-04-03T01:04:50+02:00]  INFO discord:      Connection succeeded
[2019-04-03T01:04:52+02:00]  INFO discord:      discord.ayano: joining ID:562226543590375436 (ID: ID:562226543590375436discord.ayano)
[2019-04-03T01:04:52+02:00]  INFO discord:      discord.ayano: joining ID:562724503411490847 (ID: ID:562724503411490847discord.ayano)
[2019-04-03T01:04:52+02:00]  INFO main:         Gateway(s) started succesfully. Now relaying messages
[2019-04-03T15:32:44+02:00] ERROR irc:          disconnect: error: timed out waiting for a requested PING response
[2019-04-03T15:32:44+02:00]  INFO irc:          reconnecting in 30 seconds...
[2019-04-03T15:33:13+02:00] ERROR irc:          Not connected to server, dropping message
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x614d68]

goroutine 36 [running]:
github.com/42wim/matterbridge/vendor/github.com/lrstanley/girc.(*ircConn).rate(0x0, 0x28, 0x0, 0x0)
        /home/blu/go/src/github.com/42wim/matterbridge/vendor/github.com/lrstanley/girc/conn.go:418 +0x50
github.com/42wim/matterbridge/vendor/github.com/lrstanley/girc.(*Client).Send(0x39023c0, 0x3a44000)
        /home/blu/go/src/github.com/42wim/matterbridge/vendor/github.com/lrstanley/girc/conn.go:396 +0x290
github.com/42wim/matterbridge/vendor/github.com/lrstanley/girc.(*Commands).Message(...)
        /home/blu/go/src/github.com/42wim/matterbridge/vendor/github.com/lrstanley/girc/commands.go:108
github.com/42wim/matterbridge/bridge/irc.(*Birc).doSend(0x3a80960)
        /home/blu/go/src/github.com/42wim/matterbridge/bridge/irc/irc.go:216 +0x2ac
created by github.com/42wim/matterbridge/bridge/irc.(*Birc).Connect
        /home/blu/go/src/github.com/42wim/matterbridge/bridge/irc/irc.go:102 +0x4e0

To Reproduce
I restarted my router

Expected behavior
A clean reconnect to both discord and twitch

Screenshots/debug logs

Environment (please complete the following information):

  • OS:
Linux minopia.de 4.14.98-v7+ #1200 SMP Tue Feb 12 20:27:48 GMT 2019 armv7l GNU/Linux
blu@minopia:~/go/bin $ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 9.8 (stretch)
Release:        9.8
Codename:       stretch
  • Matterbridge version: version: 1.14.2-dev

Additional context

[discord.ayano]
Token=""
Server="494877206758031363"
RemoteNickFormat="`{NICK}`: "

[irc.twitch]
Password="oauth:"
Server="irc.chat.twitch.tv:6697"
UseTLS=true
RemoteNickFormat="[Discord] {NICK}: "
Charset="utf-8"
Nick="nick"

[[gateway]]
name="Ayano"
enable=true
[[gateway.inout]]
account="discord.ayano"
channel="ID:562226543590375436"
[[gateway.inout]]
account="irc.twitch"
channel="#ayano_335"

[[gateway]]
name="NyaNekoGame"
enable=false
[[gateway.inout]]
account="discord.ayano"
channel="ID:562724503411490847"
[[gateway.inout]]
account="irc.twitch"
channel="#nyanekogame"
@42wim 42wim changed the title panic: runtime error: invalid memory address or nil pointer dereference irc: panic: runtime error: invalid memory address or nil pointer dereference Apr 4, 2019
@42wim 42wim added this to the 1.14.2 milestone Apr 6, 2019
@42wim 42wim closed this as completed in 60a8562 Apr 6, 2019
@42wim
Copy link
Owner

42wim commented Apr 6, 2019

Fixed in master, thanks for reporting.

@Bluscream
Copy link
Author

thanks :)

zeridon pushed a commit to zeridon/matterbridge that referenced this issue Feb 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants