Giter Site home page Giter Site logo

Comments (11)

 avatar commented on May 8, 2024

I noticed this happening as well. I believe it has to do with resolution. Is one of your monitors a different resolution than the other? At 1920x1080 on both of my monitors switching between the two is fine for me, and doesn't crash. When I change the resolution while the Remote Desktop is running the client crashes

from quasar.

yankejustin avatar yankejustin commented on May 8, 2024

I do have monitors with different resolutions. (1920x1080) and (1080x760). Perhaps that means that https://github.com/MaxXor/xRAT/blob/master/Client/Core/Commands/CommandHandler.cs#L226 could have something to do with this issue.

from quasar.

yankejustin avatar yankejustin commented on May 8, 2024

Accidentally closed! Sorry!

from quasar.

 avatar commented on May 8, 2024

https://github.com/MaxXor/xRAT/blob/master/Client/Core/Commands/CommandHandler.cs#L236-L239

The UnsafeStreamCodec class is throwing an exception "Bitmap width/height are not equal to previous bitmap"

Perhaps a try/catch/finally scenario could be of use? I'm not too sure how to handle it properly

from quasar.

MaxXor avatar MaxXor commented on May 8, 2024

Can you check if the fix from this branch is working for you?
https://github.com/MaxXor/xRAT/tree/remote-desktop-fix

from quasar.

 avatar commented on May 8, 2024

No it does not.

https://github.com/MaxXor/xRAT/blob/master/Client/Core/Commands/CommandHandler.cs#L236-L239

The CodeImage method throws an exception. I think adding a try/catch around this method call and setting the StreamCodec to null in the catch block, then sending a packet with a flag to tell the server to reset the stream and create a new Codec class might do the trick.

from quasar.

MaxXor avatar MaxXor commented on May 8, 2024

I just changed the monitor resolution of my second monitor to 1080x760 and no exception occured. I followed the steps from yankejustin to reproduce this issue.

from quasar.

 avatar commented on May 8, 2024

My apologies, this DID fix the issue when switching between monitors with two different resolutions.

The issue I was having was changing my resolution on the other monitor while the Remote Desktop was running, which was causing the Codec class to throw the exception.

from quasar.

MaxXor avatar MaxXor commented on May 8, 2024

Alright! :) Do you think the client should also handle the situation when someone changes the resolution?

from quasar.

 avatar commented on May 8, 2024

I think it should since its possible and bound to happen. Just another little thing to fix to have a bug-free application xD

from quasar.

MaxXor avatar MaxXor commented on May 8, 2024

Yes, hehe. :D

from quasar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.