-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Set up alternative definitions for some window messages #2925
Set up alternative definitions for some window messages #2925
Conversation
Thanks both. This doesn't affect V0.9 directly as I didn't implement the user of the named constants for neutrinordp in that branch. |
I'm going to add a note to this, as I don't understand why the definition of Consider these files:-
Then :-
However, if I move temp.h to the compiler's default include path:-
I don't get any errors, despite the macro definition still being accepted. The replacement is happening silently:-
I assume this is some gcc specialisation - clang does the same thing so I'm assuming it's not a bug. Anyone got any thoughts? |
Outstanding gcc bug request #16358 from 2004 That suggests moving the freerdp includes before the local includes will catch this. I'll rework this PR so the compiler does more of the work for us. |
FreeRDP defines macros WM_LBUTTONUP, WM_LBUTTONDOWN, WM_RBUTTONUP and WM_RBUTTONDOWN. These conflict with the definitions we have in xrdp_constants.h. Because the FreeRDP system includes followed the local includes however, the compiler did not emit a diagnostic for this - see gcc bug #16358. This PR rearranges the includes for NeutrinoRDP so the macro redefinitions are flagged by the compiler.
b569293
to
7fb70fb
Compare
I've reworked this so the compiler now catches the macro redefinitions. Consequently it's necessary to add some |
FreeRDP defines macros WM_LBUTTONUP, WM_LBUTTONDOWN, WM_RBUTTONUP and WM_RBUTTONDOWN. These conflict with the definitions we have in xrdp_constants.h. Because the FreeRDP system includes followed the local includes however, the compiler did not emit a diagnostic for this - see gcc bug #16358. This PR rearranges the includes for NeutrinoRDP so the macro redefinitions are flagged by the compiler.
FreeRDP defines macros WM_LBUTTONUP, WM_LBUTTONDOWN, WM_RBUTTONUP and WM_RBUTTONDOWN. These conflict with the definitions we have in xrdp_constants.h. Because the FreeRDP system includes followed the local includes however, the compiler did not emit a diagnostic for this - see gcc bug #16358. This PR rearranges the includes for NeutrinoRDP so the macro redefinitions are flagged by the compiler.
This fixes a regression introduced by #2864
FreeRDP silently redefines WM_LBUTTONUP, WM_LBUTTONDOWN, WM_RBUTTONUP and WM_RBUTTONDOWN. Consequently on my neutrinordp build at least, the right and left buttons don't work.
This is the least disruptive change. Renaming the defines totally will break xorgxrdp.
This probably needs backporting to v0.9 - I'll test that tomorrow.