Skip to content

Crash when resuming from suspend #253

@tauroid

Description

@tauroid

Describe the Bug

On resume from S3, Sunshine crashes with segfault. Only happens if streaming to a client at the time (Android Moonlight client).

Expected Behavior

Terminates stream cleanly before or after suspend and returns to accepting connections.

Additional Context

Coredump on resume from suspend:
PID: 1019 (sunshine)
UID: 1000 (adam)
GID: 1000 (adam)
Signal: 11 (SEGV)
Timestamp: Sat 2022-07-16 12:06:20 BST (1h 25min ago)
Command Line: /usr/bin/sunshine /home/adam/.config/sunshine/sunshine.conf
Executable: /usr/bin/sunshine
Control Group: /user.slice/user-1000.slice/user@1000.service/app.slice/sunshine.service
Unit: user@1000.service
User Unit: sunshine.service
Slice: user-1000.slice
Owner UID: 1000 (adam)
Boot ID: da11abe7bc20456f92128781808d410b
Machine ID: 07cfa7934eb340fbaf7acfbd48d7f0ab
Hostname: nusic
Storage: /var/lib/systemd/coredump/core.sunshine.1000.da11abe7bc20456f92128781808d410b.1019.1657969580000000.zst (present)
Disk Size: 1.7M
Message: Process 1019 (sunshine) of user 1000 dumped core.

            Module linux-vdso.so.1 with build-id 078847c7c4e396bf588f6a3792669fed6f0f823e
            Module libncursesw.so.6 with build-id b9917757481e6fa6097e2a1f31f5bb5eaf138c4e
            Module libedit.so.0 with build-id 4b0babfcad161c2ad0af6e59e2493258db23a331
            Module libLLVM-14.so with build-id 7b67e2807e99003f01155cb543666c25438c0cd8
            Module libxshmfence.so.1 with build-id d9b3ce4edb0b6a0818bcc57dda020d2da5e3c895
            Module libxcb-sync.so.1 with build-id 13025f6de23a271636ad321c77eda98801e62e8e
            Module libxcb-present.so.0 with build-id 8ed389d9cd6ad7110fbb00c93b32e0efaa71a6b1
            Module libxcb-dri3.so.0 with build-id 088c750254cc139e7d62b8a3fc7795a138447ccf
            Module libxcb-xfixes.so.0 with build-id e231a68d00ee4cfa12a2c31e755a9e2c1e7be450
            Module libxcb-dri2.so.0 with build-id 7bde0abc84135ae6258a8d1d130864071c2cc327
            Module libX11-xcb.so.1 with build-id f92352eae0a30aea89d11beb22367fa985288925
            Module libglapi.so.0 with build-id 3a26a3884bc8498eb637cf6edc60d9e2dfce3306
            Module libEGL_mesa.so.0 with build-id 6ea5075c6cc94935b0746f7ddbf60ddd7439aa04
            Module libGLdispatch.so.0 with build-id de981c020bd9dbdc159b11f4a2a541310cc3b8d5
            Module libEGL.so.1 with build-id 30b30de54f2f848a7b8bed469349c9a7ab1b7c22
            Module libwayland-server.so.0 with build-id 4c54fc8a7c0d4eb8adf2a69e44ebf12d16969c74
            Module libgbm.so.1 with build-id 410c1fdb97337b3b59bf508a58d8b724407b1f1e
            Module libgpg-error.so.0 with build-id 4738b8a9478177c202cccd64e0eb65d3dea2bfae
            Module libbrotlicommon.so.1 with build-id acfd597a977c8087bb6184383daae2e828a9ce42
            Module libdatrie.so.1 with build-id 6fe3b6ece2c8e7d11869fa051375128d8f808f58
            Module libgraphite2.so.3 with build-id ce58945ebb55b86d3a4e717b6eae29efc4720d8e
            Module libicudata.so.71 with build-id 4fef196388e678deb881978139e125e20ee2d94d
            Module libblkid.so.1 with build-id 140694a62d8d4d07c6c320a501f948dd1b389d73
            Module liblz4.so.1 with build-id e63600ab23b2f6997f42fac2fa56e1f02ce159a1
            Module libzstd.so.1 with build-id ab54c2881f53ab314e134f3e08c76d504376dd5d
            Module libgcrypt.so.20 with build-id 8bf3cb884124273640de797a3e77d86c98434ea4
            Module libFLAC.so.8 with build-id 3637a78858507a848ee0a48c50902c943e5bc58f
            Module libXdmcp.so.6 with build-id d864159ab0008415667db8d5f251696d75c90df2
            Module libXau.so.6 with build-id 60db1eac70f819bea9d4c366603c1583067510b4
            Module libbrotlidec.so.1 with build-id 66c54e9301f7e102ecc1d88547e5f0e8a056fe22
            Module libbz2.so.1.0 with build-id 919597c477c9b2cb9cdbb7745ed6494ac0e6da60
            Module libexpat.so.1 with build-id 113bb5a3e9ad856801bfcfc029102c9bdc13d67e
            Module libthai.so.0 with build-id a7ac5010b4275c49308021200d23690533952702
            Module libfribidi.so.0 with build-id fe9f35ac2a0074108c8306c517793f7279bd9b37
            Module libharfbuzz.so.0 with build-id aad49fa51ffb89551ebb021336f56cfa28334823
            Module libpangoft2-1.0.so.0 with build-id 1d293edcbaefc8c1b024f83d0935e88e6f09dfcb
            Module libicuuc.so.71 with build-id 633fdc0c5385d916571f6140e7a978ad0630ef55
            Module libmount.so.1 with build-id 4436aeea0cd8c01b5a77969e0531184f8b3513ce
            Module libtiff.so.5 with build-id 31895d2bd133f34f0cdc2d4ac855ed838ec927b6
            Module libjpeg.so.8 with build-id 8e6d3f3e8f438912b561c43b6e7f66e6e5e097d0
            Module libgmodule-2.0.so.0 with build-id abd986222e2cf12fc7324cb0182dfc2c8f2269c0
            Module libgomp.so.1 with build-id 5dad42990289bea94eac11b596b80f28415a8c22
            Module libasyncns.so.0 with build-id 3ed7e52f247b08f1dff19aef6a253ee4c5c785c0
            Module libsystemd.so.0 with build-id 6430b2bd03335142b596061e30d2508dc604a1b4
            Module libsndfile.so.1 with build-id 407b2376cac1726631e3f7360a9337901be04ec0
            Module libXfixes.so.3 with build-id 0a05c7e8714522bfbdd7c0027c3e2a94965664b0
            Module libmvec.so.1 with build-id 2c6aec81c79e91d66940b68be0819fdf780a976c
            Module libogg.so.0 with build-id ca0cae30a809f10db1f16e54a23b4e5ff7b2c54c
            Module libpixman-1.so.0 with build-id d2170a3ac106c2a68597bf7910ab04b1cdd69c14
            Module libxcb-shm.so.0 with build-id 828fec4d856e2710e732ea8d92c3f250c807b1c2
            Module libxcb-render.so.0 with build-id b1ca498d665807ab0ccdafbe8070853efd058173
            Module libxcb.so.1 with build-id 13d677412a71468381b11092915d231f664d18d3
            Module libXrender.so.1 with build-id 42e386d2acf3cde61081959d9671ca74acfb3edc
            Module libXext.so.6 with build-id 17beadf1cb40d41ab36629db3b4eed74110678a7
            Module libfreetype.so.6 with build-id f89dd5502e75aca28fb5c3ccd0dbd26fe822bfef
            Module libfontconfig.so.1 with build-id 36be6951b8c1e42a7dd05684a37400fc8ef9147c
            Module libpng16.so.16 with build-id 2dc0bce07f199bf983c07a05fb95a6f4af83a9b3
            Module libpcre.so.1 with build-id 845483dd0acba86de9f0313102bebbaf3ce52767
            Module libpango-1.0.so.0 with build-id b358a862a5ca8b1e4e69235edce1780e9f860a0a
            Module libpangocairo-1.0.so.0 with build-id e7a2a9e56f2e2f6121d9c5741b3e93871b673cfa
            Module libxml2.so.2 with build-id 8cdf00fa954d9a27f2f184c4d354cb14677446ac
            Module libgio-2.0.so.0 with build-id 7a769ec24a9a705d04ee0297730032f70ed0835b
            Module libgdk_pixbuf-2.0.so.0 with build-id 5b8422ab971b1a8a8e1c43b88738d4ee217f609e
            Module libcairo-gobject.so.2 with build-id 9927090dddfb180365695a8f37d1cac89463f109
            Module libpthread.so.0 with build-id 95ae4f30a6f12ccbff645d30f8e1a3ee23ec7d36
            Module libsoxr.so.0 with build-id 9e49936ed807c1e52705b88d5d71706fe11d9ed1
            Module ld-linux-x86-64.so.2 with build-id 0effd0e43efa4468d3c31871c93af0b7f3005673
            Module libdbus-1.so.3 with build-id 7f4b16b4b407cbae2d7118d6f99610e29a18a56a
            Module libpulsecommon-16.1.so with build-id 17e5c781f557e60fbc789cb631816a4a29230f4a
            Module libffi.so.8 with build-id f0a9586cf0f42d2b9971bd1065ca3a6b19f4a2c2
            Module libX11.so.6 with build-id 21e886e968772b7964d646f54c1faecc56734de9
            Module libvdpau.so.1 with build-id fccd021ff13c37ebf7144d184a3250624e086f52
            Module libva-x11.so.2 with build-id 904eb0006b0ef7a4bcd560b9e016711066e410b8
            Module libva-drm.so.2 with build-id 58df7fa92e899fee0c784db7a9fc68bb107156b6
            Module libmfx.so.1 with build-id d817dae78e0662e7206a66a41843a66cf0fb0b2f
            Module libva.so.2 with build-id 86d5ae6b358ba79962131649d99e42e1ba669501
            Module libxvidcore.so.4 with build-id 43bc390a7842a7ca3a0302e93442ea561d7f013a
            Module libx265.so.199 with build-id 4fd2d7155725df753c6b32274c442349fc05e632
            Module libx264.so.164 with build-id 1ebb8708f2101bd1c95b701142163133e8dac465
            Module libvorbisenc.so.2 with build-id 2b1ce7fcdcc925bc663ebe2c1c008c0dd96e5bd0
            Module libvorbis.so.0 with build-id f4e086347f6c1a66eb73cfe13974a29bd39aabca
            Module libtheoradec.so.1 with build-id 19d321fd5455c7b7611ca9602a804b496124e06f
            Module libtheoraenc.so.1 with build-id cde750f0621140f313e4ef4e5f212e662f24a38b
            Module libSvtAv1Enc.so.1 with build-id d95f643a00090915d6f17c27a84a031c45e819f3
            Module libspeex.so.1 with build-id fd7a3d6df98e453f2513c929f26950060ec8ff48
            Module librav1e.so.0 with build-id 5f8fc2c271f0d96480ab1c71447e038a66aa1c57
            Module libopenjp2.so.7 with build-id 5fa7037f0c932c285735dbcd42365abe6c3abb05
            Module libopencore-amrnb.so.0 with build-id a3d78948c85fa235e66549119b2f130e69af7b70
            Module libmp3lame.so.0 with build-id 48c901805551a3dd58d02502c4cd67f6aa848107
            Module libgsm.so.1 with build-id 1cc6240f7eaedaaac302bc7c0f64ebbeae596f22
            Module libaom.so.3 with build-id 2b5b58e482957529f8b14aecb5b2acc21362d04d
            Module libz.so.1 with build-id fefe3219a96d682ec98fcfb78866b8594298b5a2
            Module libcairo.so.2 with build-id a222d042e56108d2786ece7bf291b56ba2069591
            Module libglib-2.0.so.0 with build-id 1340f3a762b2293ebf6d725edf0eb14839f85317
            Module libgobject-2.0.so.0 with build-id a7515bd8cd51064d187953c0f506a43958de31a6
            Module librsvg-2.so.2 with build-id 1cb5dfb747cdb53ba90f504acbe23de518c29ad9
            Module libopencore-amrwb.so.0 with build-id 28da8ed3dfca59280e835c46bd40da295dae99e2
            Module libdav1d.so.6 with build-id a93560a23a7f1def734a3cf54f09eadd7c3c46e9
            Module liblzma.so.5 with build-id 28b40c7af8098a66af6ee093b6986b91cad7694d
            Module libwebp.so.7 with build-id 0add7a572705244ed810b7e722cce7da0dcfb62c
            Module libwebpmux.so.3 with build-id 4232d5263a45719ba12f58ed7d8cae3a0fc887de
            Module libvpx.so.7 with build-id accaef32c955264d758e0348e7da476c5979d711
            Module libswresample.so.3 with build-id 1686600b5ddbb9aaa311af78ce22414238d2f5a8
            Module libc.so.6 with build-id 60df1df31f02a7b23da83e8ef923359885b81492
            Module libgcc_s.so.1 with build-id 0e3de903950e35ae59a5de8c00b1817a4a71ca01
            Module libm.so.6 with build-id 1b7296ef9fd806e47060788389293c824b09ad72
            Module libstdc++.so.6 with build-id b3eaebcb5369487562e52dd8d016c9cd77f80c54
            Module libpulse-simple.so.0 with build-id 7879cf719df0389789b262cf61606de309ebf227
            Module libpulse.so.0 with build-id 0c1618cb1e11cc14128914e45965433374cbd10e
            Module libevdev.so.2 with build-id 09eb82a0dfca98325f54b3918875cff09a5c1428
            Module libwayland-client.so.0 with build-id 515c72111400d7bdbfbdfcec78d597e4986a5943
            Module libcap.so.2 with build-id 21b00ab76bb16fde56fd741f07233c78069f0579
            Module libdrm.so.2 with build-id 39847bc84bc769f632f8f599a62fdcc98c9270cd
            Module libcrypto.so.1.1 with build-id 7981ea3d69f3c28e46ee312a815af96eab93775c
            Module libssl.so.1.1 with build-id e6b1f97a5b60b4248c49dfc5b11f53f281b507d0
            Module libswscale.so.5 with build-id f50d7b750afc41e5c016596b4ba2a62c063cd4c1
            Module libavutil.so.56 with build-id 4555dce49cfc4adb7e21528ca37a9278f5e49c64
            Module libavcodec.so.58 with build-id ab055f751bda677d280699d828b170add357ee13
            Module libopus.so.0 with build-id 35fafc4024675e9cfe57c7d50c3965eac6bac358
            Module sunshine with build-id ae000c0089d7164cee65a51699b8eb32031860c2
            Stack trace of thread 1019:
            #0  0x00007fb9f0b5ce1d n/a (libc.so.6 + 0x16de1d)
            #1  0x00007fb9f0dc883c memchr (libstdc++.so.6 + 0xc683c)
            #2  0x000055e91b290ddb n/a (sunshine + 0xeaddb)
            #3  0x000055e91b3d0840 _ZN2va8validateEi (sunshine + 0x22a840)
            #4  0x000055e91b3b460d _ZN5platf11kms_displayENS_10mem_type_eERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi (sunshine + 0x20e60d)
            #5  0x000055e91b3e962d _ZN5platf7displayENS_10mem_type_eERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi (sunshine + 0x24362d)
            #6  0x000055e91b36b714 _ZN5video13reset_displayERSt10shared_ptrIN5platf9display_tEE14AVHWDeviceTypeRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi (sunshine + 0x1c5714)
            #7  0x000055e91b372783 _ZN5video15validate_configERSt10shared_ptrIN5platf9display_tEERKNS_9encoder_tERKNS_8config_tE (sunshine + 0x1cc783)
            #8  0x000055e91b37350e _ZN5video16validate_encoderERNS_9encoder_tE (sunshine + 0x1cd50e)
            #9  0x000055e91b374307 _ZN5video4initEv (sunshine + 0x1ce307)
            #10 0x000055e91b28443e main (sunshine + 0xde43e)
            #11 0x00007fb9f0a18290 n/a (libc.so.6 + 0x29290)
            #12 0x00007fb9f0a1834a __libc_start_main (libc.so.6 + 0x2934a)
            #13 0x000055e91b287f35 _start (sunshine + 0xe1f35)
            
            Stack trace of thread 1032:
            #0  0x00007fb9f0a78119 n/a (libc.so.6 + 0x89119)
            #1  0x00007fb9f0a7a920 pthread_cond_wait (libc.so.6 + 0x8b920)
            #2  0x00007fb9f0dd0d71 __gthread_cond_wait (libstdc++.so.6 + 0xced71)
            #3  0x000055e91b2a771f _ZN4util10ThreadPool5_mainEv (sunshine + 0x10171f)
            #4  0x00007fb9f0dd8183 execute_native_thread_routine (libstdc++.so.6 + 0xd6183)
            #5  0x00007fb9f0a7b54d n/a (libc.so.6 + 0x8c54d)
            #6  0x00007fb9f0b00874 __clone (libc.so.6 + 0x111874)
            
            Stack trace of thread 1040:
            #0  0x00007fb9f0ac6fd5 clock_nanosleep (libc.so.6 + 0xd7fd5)
            #1  0x00007fb9f0acbb97 __nanosleep (libc.so.6 + 0xdcb97)
            #2  0x000055e91b3f9531 _ZN5platf15broadcastRumbleERN4safe7queue_tISt5tupleIJiP15libevdev_uinputSt10shared_ptrINS0_6post_tINS1_INS_8rumble_tEEEEEENS_8pollfd_tEEEEE (sunshine + 0x253531)
            #3  0x00007fb9f0dd8183 execute_native_thread_routine (libstdc++.so.6 + 0xd6183)
            #4  0x00007fb9f0a7b54d n/a (libc.so.6 + 0x8c54d)
            #5  0x00007fb9f0b00874 __clone (libc.so.6 + 0x111874)
            
            Stack trace of thread 1031:
            #0  0x00007fb9f0afa30d syscall (libc.so.6 + 0x10b30d)
            #1  0x000055e91b480303 _ZN5boost3log12v2s_mt_posix3aux18atomic_based_event4waitEv (sunshine + 0x2da303)
            #2  0x000055e91b2ad601 _ZN5boost6detail11thread_dataINS_3log12v2s_mt_posix5sinks17asynchronous_sinkINS4_26basic_text_ostream_backendIcEENS4_20unbounded_fifo_queueEE8run_funcEE3runEv (sunshine + 0x107601)
            #3  0x000055e91b48f9cb n/a (sunshine + 0x2e99cb)
            #4  0x00007fb9f0a7b54d n/a (libc.so.6 + 0x8c54d)
            #5  0x00007fb9f0b00874 __clone (libc.so.6 + 0x111874)
            ELF object binary architecture: AMD x86-64

Sunshine Host Operating System and Version

Manjaro rolling

Architecture

x86_64

Sunshine Version

0.13.0

GPU Type

Intel

GPU Model

Mesa Intel® Xe Graphics (TGL GT2)

GPU Driver/Mesa Version

Mesa 22.1.3

Capture Method (Linux Only)

VAAPI kmsgrab

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions