{"action":"created","issue":{"url":"https://api.github.com/repos/strukturag/spreed-webrtc/issues/155","labels_url":"https://api.github.com/repos/strukturag/spreed-webrtc/issues/155/labels{/name}","comments_url":"https://api.github.com/repos/strukturag/spreed-webrtc/issues/155/comments","events_url":"https://api.github.com/repos/strukturag/spreed-webrtc/issues/155/events","html_url":"https://github.com/strukturag/spreed-webrtc/issues/155","id":51153830,"number":155,"title":"Invalid memory address or nil pointer derefence after putting server to background","user":{"login":"fancycode","id":247730,"avatar_url":"https://avatars.githubusercontent.com/u/247730?v=3","gravatar_id":"","url":"https://api.github.com/users/fancycode","html_url":"https://github.com/fancycode","followers_url":"https://api.github.com/users/fancycode/followers","following_url":"https://api.github.com/users/fancycode/following{/other_user}","gists_url":"https://api.github.com/users/fancycode/gists{/gist_id}","starred_url":"https://api.github.com/users/fancycode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fancycode/subscriptions","organizations_url":"https://api.github.com/users/fancycode/orgs","repos_url":"https://api.github.com/users/fancycode/repos","events_url":"https://api.github.com/users/fancycode/events{/privacy}","received_events_url":"https://api.github.com/users/fancycode/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/strukturag/spreed-webrtc/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":{"login":"deathwish","id":486298,"avatar_url":"https://avatars.githubusercontent.com/u/486298?v=3","gravatar_id":"","url":"https://api.github.com/users/deathwish","html_url":"https://github.com/deathwish","followers_url":"https://api.github.com/users/deathwish/followers","following_url":"https://api.github.com/users/deathwish/following{/other_user}","gists_url":"https://api.github.com/users/deathwish/gists{/gist_id}","starred_url":"https://api.github.com/users/deathwish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deathwish/subscriptions","organizations_url":"https://api.github.com/users/deathwish/orgs","repos_url":"https://api.github.com/users/deathwish/repos","events_url":"https://api.github.com/users/deathwish/events{/privacy}","received_events_url":"https://api.github.com/users/deathwish/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2014-12-05T22:30:05Z","updated_at":"2015-04-16T22:06:42Z","closed_at":null,"body":"This is probably an edge case but I wanted to share anyway. Go panics like the following happen if you have clients connected to the server, put it in the background for a couple of seconds and resume it.\r\n\r\n```\r\nserver 2014/12/05 23:27:12.302643 http: panic serving 127.0.0.1:59226: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 24 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc21014e160)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc21014e160, 0xc210079840)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc21014e160, 0xc21019600a, 0x22c, 0xc21014e160, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2100bcbe0, 0xc21018c000)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2100bcbe0, 0xc21018c000)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2100bcbe0, 0xc21018c000)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2100bcbe0, 0xc21018c000)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013f080)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.302697 http: panic serving 127.0.0.1:59256: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 43 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc2101c3790)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc2101c3790, 0xc210115540)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc2101c3790, 0xc21016f24a, 0x22c, 0xc2101c3790, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc210073500, 0xc2101619c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc210073500, 0xc2101619c0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc210073500, 0xc2101619c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc210073500, 0xc2101619c0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013f800)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.302751 http: panic serving 127.0.0.1:59260: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 45 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc2102249a0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc2102249a0, 0xc2100f1a80)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc2102249a0, 0xc2101bab4a, 0x22c, 0xc2102249a0, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2100e6820, 0xc2101c4820)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2100e6820, 0xc2101c4820)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2100e6820, 0xc2101c4820)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2100e6820, 0xc2101c4820)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013fb00)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.302805 http: panic serving 127.0.0.1:59252: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 40 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc210199160)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc210199160, 0xc2100f1540)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc210199160, 0xc2101ae6ca, 0x22c, 0xc210199160, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2101ef140, 0xc2101ab4e0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2101ef140, 0xc2101ab4e0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2101ef140, 0xc2101ab4e0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2101ef140, 0xc2101ab4e0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013f700)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.302836 Created new session token 556 MTQxNzgxODQzMnxjdmhENFJybDFGMmhVOGYtVV9Jd2lYb0R0dmpRRlgyM0FudnlDUmNOUDVCQ0lWVDRSb0tiVXpnbUN0cC1tQjExd1pTSmtHMWlLd2ZFZXpDelAtVUhJdXFoU2xtZktrNmdBS2ZqSHhfaDlkQUw0azVSOVFaenprdlNvQ3hkMWxNQjNkRV9wQm5QRUlFNmJuYUliVVQwS3M3NFU2XzBqVTVZTWpDaXB2MUdwNDRta0xlaUVSM1lFeGVFTFFiVDQyS0tWQ3RlQ3gzc2lnNUxMY0FDVGx0RThvc1JzWjdBU09INmlJVmZpTTNNdUdGYmxOM3ZWajhXaTFsZDViSEhQckEyOWNDZzdhV29XT0NzU1BRU09SZWJVR0NXRGtBbjE5T1RucXMwckJyT2Zna284UnRhbnJqTUhoUkFoZkQwWlJjc2tTdzB5Q3Q4RWJ0MkxsSnEzUC1HNGpocE13bG1RM09ESnlOZWJETkt6WGhzWjRuR2NRPT18SwPhwGXbtIqi_K9qBJK2uXCM18xE0I-NolBUEyeywYU=\r\nserver 2014/12/05 23:27:12.312787 http: panic serving 127.0.0.1:59254: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 41 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc21009ed10)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc21009ed10, 0xc21024b0c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc21009ed10, 0xc2100f900a, 0x22c, 0xc21009ed10, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2101ef500, 0xc21018c820)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2101ef500, 0xc21018c820)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2101ef500, 0xc21018c820)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2101ef500, 0xc21018c820)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013f780)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.302117 Created new session token 556 MTQxNzgxODQzMnx4b19CaWh3Nm54T0EtdUdhOWdjaWJQamE1cVBBVkRCNFh5YVJBYndwVjdxcGF3SC15dHdGV2c1bnN2V3JMcTg3b3FqcGU3clJOTUVZdkpGRV9HdDVCNWVCUU1vb1lvNFJhekdSNWVDb2V3Y0k5bmJDTHRoSHpQT3ZEcUVVQ2tmWFNVd2htV2VPWnI4TDhRVFh2VEc5TmFaeHB0dVVpU2FPMlFzcHk5ZWtZX2tJRVJndGFVMWtyQ1pFOHJyUnA0R2ZmazhLUUp6TUhKQTZiUjFSbGxJRFkyc1FfZHlhZVFzcWIwQ01GX1pvV0I1bXlvVUVWLTZMUDUyZ1RSUE8ySkJyRUpfdUJSNjdFcEtNSHZpcl8zd2xtaUF5OEVyUHNnQTRRSWZkT2F2V2UwcW51LVdDYTVFZ1U1ejdaLXhlaC05SmtFYk5sYlRCMFZSWEF3MHFtajRIdG02TjdWM2NoM0tqU3k5b1dUaEx5Q25VUXZub0J3PT18dv92dkAi4VvZC4J_83zPtZH_TO4R3ZihZ4hh7S5aSdc=\r\nserver 2014/12/05 23:27:12.314244 http: panic serving 127.0.0.1:59270: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 52 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc2102652c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc2102652c0, 0xc210115a80)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc2102652c0, 0xc21027724a, 0x22c, 0xc2102652c0, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2100e6460, 0xc21029d000)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2100e6460, 0xc21029d000)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2100e6460, 0xc21029d000)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2100e6460, 0xc21029d000)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013fd80)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.314272 http: panic serving 127.0.0.1:59262: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 48 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc21024d2c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc21024d2c0, 0xc21024b3c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc21024d2c0, 0xc21025f00a, 0x22c, 0xc21024d2c0, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2101ef6e0, 0xc2102510d0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2101ef6e0, 0xc2102510d0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2101ef6e0, 0xc2102510d0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2101ef6e0, 0xc2102510d0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013fb80)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.314326 http: panic serving 127.0.0.1:59268: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 51 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc210272f20)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc210272f20, 0xc2100f1d80)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc210272f20, 0xc21026190a, 0x22c, 0xc210272f20, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2100e6a00, 0xc2102920d0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2100e6a00, 0xc2102920d0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2100e6a00, 0xc2102920d0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2100e6a00, 0xc2102920d0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013fd00)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.314374 http: panic serving 127.0.0.1:59264: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 49 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc21024a6e0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc21024a6e0, 0xc210079b40)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc21024a6e0, 0xc21026624a, 0x22c, 0xc21024a6e0, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc2100bcdc0, 0xc2100f45b0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc2100bcdc0, 0xc2100f45b0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc2100bcdc0, 0xc2100f45b0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc2100bcdc0, 0xc2100f45b0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013fc00)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\nserver 2014/12/05 23:27:12.316375 Error while reading 27 unexpected EOF\r\nserver 2014/12/05 23:27:12.316446 Error while writing 27 write tcp 127.0.0.1:59248: broken pipe\r\nserver 2014/12/05 23:27:12.316607 http: panic serving 127.0.0.1:59272: runtime error: invalid memory address or nil pointer dereference\r\ngoroutine 53 [running]:\r\nnet/http.func·009()\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1093 +0xae\r\nruntime.panic(0x769be0, 0xc09cc8)\r\n\t/usr/lib/go/src/pkg/runtime/panic.c:248 +0x106\r\nmain.(*Session).Userid(0x0, 0x0, 0x0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/session.go:230 +0x82\r\nmain.(*Server).OnRegister(0x0, 0xc2102a3000)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/server.go:47 +0x1a8\r\nmain.(*Hub).registerHandler(0xc2100ab480, 0xc2102a3000, 0xc2102b80c0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/hub.go:383 +0x1a9\r\nmain.(*Connection).reregister(0xc2102a3000, 0xc2101e3d8a, 0x22c, 0xc2102a3000, 0x22c)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/connection.go:127 +0xae\r\nmain.func·018(0x7faf36d881a8, 0xc210073a00, 0xc2100378f0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/src/app/spreed-webrtc-server/ws.go:78 +0x273\r\nnet/http.HandlerFunc.ServeHTTP(0xc21007f790, 0x7faf36d881a8, 0xc210073a00, 0xc2100378f0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1220 +0x40\r\ngithub.com/gorilla/mux.(*Router).ServeHTTP(0xc210080280, 0x7faf36d881a8, 0xc210073a00, 0xc2100378f0)\r\n\t/home/magog/develop/struktur/spreedme/spreed-speakfreely/vendor/src/github.com/gorilla/mux/mux.go:98 +0x21c\r\nnet/http.serverHandler.ServeHTTP(0xc2100a6700, 0x7faf36d881a8, 0xc210073a00, 0xc2100378f0)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1597 +0x16e\r\nnet/http.(*conn).serve(0xc21013fe00)\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1167 +0x7b7\r\ncreated by net/http.(*Server).Serve\r\n\t/usr/lib/go/src/pkg/net/http/server.go:1644 +0x28b\r\n```"},"comment":{"url":"https://api.github.com/repos/strukturag/spreed-webrtc/issues/comments/93850329","html_url":"https://github.com/strukturag/spreed-webrtc/issues/155#issuecomment-93850329","issue_url":"https://api.github.com/repos/strukturag/spreed-webrtc/issues/155","id":93850329,"user":{"login":"deathwish","id":486298,"avatar_url":"https://avatars.githubusercontent.com/u/486298?v=3","gravatar_id":"","url":"https://api.github.com/users/deathwish","html_url":"https://github.com/deathwish","followers_url":"https://api.github.com/users/deathwish/followers","following_url":"https://api.github.com/users/deathwish/following{/other_user}","gists_url":"https://api.github.com/users/deathwish/gists{/gist_id}","starred_url":"https://api.github.com/users/deathwish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deathwish/subscriptions","organizations_url":"https://api.github.com/users/deathwish/orgs","repos_url":"https://api.github.com/users/deathwish/repos","events_url":"https://api.github.com/users/deathwish/events{/privacy}","received_events_url":"https://api.github.com/users/deathwish/received_events","type":"User","site_admin":false},"created_at":"2015-04-16T22:06:42Z","updated_at":"2015-04-16T22:06:42Z","body":"I cannot reproduce this on current `develop` branch. Based on the log spew that results from backgrounding the server as described, I believe the session replacement patches may have eliminated this bug. Recommend closing invalid unless @fancycode can reproduce with latest sources."}}