HISE Logo Forum
    • Categories
    • Register
    • Login

    Plugin Crashing DAW when quitting (Hardcoded FX, Preset System)

    Scheduled Pinned Locked Moved Bug Reports
    crashdaw
    9 Posts 4 Posters 196 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • oskarshO
      oskarsh
      last edited by

      There is a bug which is crashing the DAW when removing the Plugin from the chain.

      What I found so far is

      • using 4 channels
      • using hardcodedFX or Effect slots
      • use Engine.addModuleStateToUserPreset('HardcodedMasterFX1');
      • switching preset where the preset will change the loaded network order

      The bug can be triggered by changing presets, then removing the plugin from the FX Chain inside the DAW. To replicate this inside HISE simply quit HISE.

      It seems like this bug is in the clearPreset() function in HISE which is executed when the Plugin is exited or quit.
      This will crash the entire DAW, especially in Ableton and FL Studio. Some DAWs handle it more gracefully.

      There is no debug log created by the Plugin but I could trace the issue to the clearPreset() function. I assume it has something todo with using more than 2 channels and looks like a read access violation, trying to remove what has already been removed.

      How can I debug this further. I feel like this is pretty severe since crashing the DAW is really bad.

      @Christoph-Hart can you help out here?

      Thread 0 Crashed:: MainThread Dispatch queue: com.apple.main-thread
      0   Reach                         	       0x33bcc22f0 hise::HardcodedSwappableEffect::~HardcodedSwappableEffect() + 640
      1   Reach                         	       0x33bcc53ac hise::HardcodedMasterFX::~HardcodedMasterFX() + 288
      2   Reach                         	       0x33bcbd390 hise::SlotFX::~SlotFX() + 136
      3   Reach                         	       0x33bb277d0 hise::Chain::Handler::clearAsync(hise::Processor*) + 340
      4   Reach                         	       0x33baf48a0 hise::MainController::clearPreset(juce::NotificationType)::$_0::operator()(hise::Processor*) const + 712
      5   Reach                         	       0x33baf43f4 hise::MainController::clearPreset(juce::NotificationType) + 524
      6   Reach                         	       0x33bd4bfac hise::FrontendProcessor::~FrontendProcessor() + 776
      7   Reach                         	       0x33bd498c8 hise::FrontendProcessor::~FrontendProcessor() + 12
      8   Reach                         	       0x33ba03118 juce::JuceAudioProcessor::~JuceAudioProcessor() + 364
      9   Reach                         	       0x33ba02fa4 juce::JuceAudioProcessor::~JuceAudioProcessor() + 12
      10  Reach                         	       0x33ba02918 juce::JuceAudioProcessor::release() + 48
      11  Reach                         	       0x33ba0a63c juce::JuceVST3Component::~JuceVST3Component() + 220
      12  Reach                         	       0x33ba061f0 juce::JuceVST3Component::~JuceVST3Component() + 12
      13  Reach                         	       0x33ba0a090 non-virtual thunk to juce::JuceVST3Component::release() + 44
      14  Live                          	       0x10501fde4 0x102bb8000 + 38174180
      

      breathing HISE

      oskarshO 1 Reply Last reply Reply Quote 0
      • oskarshO
        oskarsh @oskarsh
        last edited by

        @oskarsh Users have reported that this was working a version ago so I assume there has been a change in HISE since I recompiled my plugin using a later version again.

        breathing HISE

        orangeO 1 Reply Last reply Reply Quote 0
        • orangeO
          orange @oskarsh
          last edited by

          @oskarsh It might be related to this:

          Link Preview Image
          Using 2 and multiple channels together in the Effect Slot

          Can't we use the Effect Slot channels more than 2? Apparently, custom nodes with more than 2 channels cannot be opened loaded to the HardcodedMasterFX unit i...

          favicon

          Forum (forum.hise.audio)

          develop Branch / XCode 13.1
          macOS Monterey / M1 Max

          oskarshO 1 Reply Last reply Reply Quote 0
          • oskarshO
            oskarsh @orange
            last edited by

            @orange I am getting weird behavior when using the Engine.addToModuleState() function.

            I feel like its related to the multichannel issue and it always assumes 2 channels are used. I hit a roadblock here. Maybe @Christoph-Hart can help.

            breathing HISE

            bendursoB 1 Reply Last reply Reply Quote 1
            • bendursoB
              bendurso @oskarsh
              last edited by

              @oskarsh Did you realize if that was the problem? I'm starting to think that my plugin crashes when using Engine.addToModuleState() with slot fxs.

              oskarshO 1 Reply Last reply Reply Quote 0
              • oskarshO
                oskarsh @bendurso
                last edited by

                @bendurso yes after days of troubleshooting I found that your scriptnode networks cannot have more than 16 Parameters and use the Effect Slots as hardcoded FX.

                It would actually crash when you change the order of the effects by using swap effects via a preset change. When one of the effects is the one with more than 16 Parameters and its getting swapped around.

                this would actually in some DAWs crash the entire DAW like in FL Studio or Ableton.

                Took long time to find, this bug is one for @Christoph-Hart

                breathing HISE

                LindonL 1 Reply Last reply Reply Quote 2
                • LindonL
                  Lindon @oskarsh
                  last edited by Lindon

                  @oskarsh said in [Plugin Crashing DAW when quitting (Hardcoded FX, Preset System)]

                  Took long time to find, this bug is one for @Christoph-Hart

                  Did you log it as a bug/issue in github?

                  HISE Development for hire.
                  www.channelrobot.com

                  oskarshO 2 Replies Last reply Reply Quote 0
                  • oskarshO
                    oskarsh @Lindon
                    last edited by

                    @Lindon will do, found this a couple days ago

                    breathing HISE

                    1 Reply Last reply Reply Quote 0
                    • oskarshO
                      oskarsh @Lindon
                      last edited by

                      @Lindon https://github.com/christophhart/HISE/issues/741

                      done

                      breathing HISE

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post

                      50

                      Online

                      1.7k

                      Users

                      11.7k

                      Topics

                      101.8k

                      Posts