Commit Graph

217 Commits

Author SHA1 Message Date
akallabeth
3d9dcaece7
[out-of-bounds] fix oob reads 2025-03-11 09:37:11 +01:00
akallabeth
ca964f7c7d
[mkstemp] set umask 2025-03-11 09:37:07 +01:00
akallabeth
00fecc61bb
[uwac,rdtk] remove duplicated BUILD_TESTING_INTERNAL 2025-03-06 15:30:32 +01:00
akallabeth
a24ffe957c
[cmake] make C and C++ standards configurable
use cache variables to allow overriding them from command line
2025-02-13 13:30:06 +01:00
akallabeth
0ae7c4b52d
[cmake] refactor configuration
* Split common stuff to reusable files
* Disable INTERPROCEDURAL_OPTIMIZATION for SDL2/3 resource targets
2025-02-11 11:33:34 +01:00
akallabeth
ea2022b76b
[clang,tidy] fix warnings 2025-01-15 09:32:52 +01:00
akallabeth
c535d8d4a6
[uwac] fix narrowing int cast 2025-01-07 21:28:16 +01:00
akallabeth
e061c02747
[uwac] fix integer cast warnings 2024-12-19 11:36:07 +01:00
akallabeth
43bfc74721
[cmake] install only header files
skip empty directories on install
2024-12-15 17:54:54 +01:00
akallabeth
180a9d7d72
[cmake,flags] print all configuration flags
Since we do not know wich configuration will be build with
multiconfiguration generators print out all C_FLAGS_XXX and
CXX_FLAGS_XXX variables
2024-12-05 09:36:26 +01:00
akallabeth
ba8fd2ada5
[cmake] force configuration options
limit multiconfiguration options to supported types
2024-12-05 09:36:23 +01:00
akallabeth
faae38120c
[cmake,format] reformat all cmake files 2024-11-27 20:41:48 +01:00
stephanebill
4f2afa8c47 spell check with codespell 2024-11-20 16:53:40 -05:00
akallabeth
aa954d9be9
[warnings] fix various compiler warnings 2024-10-29 15:49:43 +01:00
akallabeth
a27d9508e2
[cmake] unify CFLAGS to string
* move to common CMake function
* escape CFLAGS
2024-10-25 11:40:43 +02:00
akallabeth
1675d926d2
Merge pull request #10776 from akallabeth/packaging-tests
[cmake] split tests
2024-10-24 11:26:17 +02:00
akallabeth
de055a6765
Merge pull request #10777 from akallabeth/cmake-build-type
[cmake] enforce a supported build type
2024-10-24 09:47:47 +02:00
Armin Novak
527db6783b
[cmake] split tests
* Keep BUILD_TESTING, but only run tests compatible with API (for
  packaging)
* Add BUILD_TESTING_INTERNAL for all tests including internal function
  tests that modify API to be run on our CI
2024-10-24 09:45:44 +02:00
akallabeth
aa9b03df25
[cmake] generate full buildflags.h CFLAGS
Combine current configuration flags with CMAKE_C_FLAGS
2024-10-24 09:08:08 +02:00
Armin Novak
0545a8a5ef
[uwac] fix sign warnings 2024-10-23 11:02:52 +02:00
akallabeth
cfc37caeb8
[cmake] cleaning_configure_file
add a wrapper to automatically add generated files to clean target
2024-10-02 23:28:08 +02:00
akallabeth
ba47e1936f
[uwac] add strerror_r detection and use 2024-09-30 15:41:52 +02:00
akallabeth
861f699d92
[uwac] fix uwac seat functions
change arguments to match prototypes
2024-09-11 20:49:03 +02:00
akallabeth
e864fed61f
[uwac] disable clang-tidy for generated files 2024-09-11 20:48:43 +02:00
akallabeth
5e123735fa
[warnings] fixed sign-compare 2024-09-04 10:14:05 +02:00
akallabeth
72ae7fb54f
[nolint] add cert-dcl37-c,cert-dcl51-cpp 2024-09-03 12:24:48 +02:00
Armin Novak
fe4cb6de65
[warnings] fix float/double warnings 2024-09-02 16:20:20 +02:00
akallabeth
7c1fd71b7b
[uwac] elminate pedantic warnings from defines 2024-08-30 15:40:08 +02:00
akallabeth
457d6f7578
[warnings] fix clang-tidy issues in uwac 2024-08-29 15:20:45 +02:00
akallabeth
1d33095500
[warnings] fix cert-err33-c
Fix unused return values, cast to void if on purpose
2024-08-29 10:19:27 +02:00
akallabeth
b0afe43d34
[uwac] remove broken function attribute 2024-08-28 08:50:17 +02:00
akallabeth
56d660f258
[cmake] mark dependency includes SYSTEM
Mark all dependency include paths SYSTEM so warnings from system headers
are excluded from ci warning statistics
2024-08-26 11:10:49 +02:00
akallabeth
86e2789d9b
[coverity] fix warnings 2024-08-26 09:19:06 +02:00
Armin Novak
6289482283
[uwac] fix compiler warnings 2024-07-22 11:06:13 +02:00
Armin Novak
1024a1a195 Revert "[coverity] 1543170 Resource leak"
This reverts commit d24bb658ec.
2024-07-04 12:11:26 +02:00
Armin Novak
e71da381cc
[uwac] fix wrong data type 2024-07-03 14:03:24 +02:00
akallabeth
0f567c9ac5
[uwac,window] fix size_t additions 2024-07-02 13:17:12 +02:00
akallabeth
4099bd4e45
[warnings] integer casts/checks 2024-07-02 12:38:00 +02:00
akallabeth
c07ba558cb
[warnings] fix various compiler warnings 2024-06-04 13:23:24 +02:00
Mariusz Bialonczyk
839f3e8408 uwac: fix window handling/viewport
Parameters passed to wp_viewport_set_destination was scaled instead of
the actual window size. In fact I noticed this problem when I was
testing the initial change (c29ba7985) but was not sure about how to fix
this and moreover, the tiling manager which I am using (sway) is
immediatelly tiling the window and all seems fine in day-to-day use
with tiled window.
The problem was only visible when the window was changed to floating:
the window content was scaled properly but the viewport was twice as
big (thus a whole window). What is worse it seems that the scaling was
done multiple times making a huge window size in some circumstances.

Now in new sway version 1.9 authors added an assert which prevents from
having a window which overlaps different renderers and this also trigger
this problem in FreeRDP, because when starting the window size was too
big.
This was leading to:
wp_viewport@31: error 2: source rectangle out of buffer bounds
or even sway crash

This commit is fixing this problem by using a proper window size values
(initially passed to a function and saved to additional variables before
scaling calculation).
Window size is now correct even when changed to a floating window.
2024-04-23 12:19:00 +02:00
akallabeth
0d09ae9ad4 [coverity] 1543074 Dereference before null check 2024-04-12 12:41:42 +02:00
akallabeth
d24bb658ec [coverity] 1543170 Resource leak 2024-04-12 09:45:09 +02:00
akallabeth
d7ebec5a65 [tidy] move loop variable declaration to loop 2024-02-22 12:31:50 +01:00
akallabeth
0ba995655d [clang-tidy] cppcoreguidelines-init-variables 2024-02-15 11:49:16 +01:00
akallabeth
207def5c56 [clang-tidy] readability-isolate-declaration 2024-02-15 11:49:16 +01:00
akallabeth
a7fb0d5c75 [uwac] add missing library link 2024-02-09 10:29:08 +01:00
Mariusz Bialonczyk
4c17dfb71d [uwac] output: take a max scale into scaling code
Fix for a hybrid multimonitor configurations:
Previous code was working for me because the display with scale=2
was last on the wayland display list. After restarting it was earlier.
To fix this - just take the highest scale provided by a display.
Similar as eg. here the SDL is doing:
b5bc64aa55/src/video/wayland/SDL_waylandwindow.c (L1170)
2024-01-11 16:00:40 +01:00
Mariusz Bialonczyk
26017c71bd [uwac] input: release pressed keys when loosing window focus
The commit is fixing the problem when eg. a user is pressing some
modifier key to switch from active FreeRDP window and when get back to
that window, it "virtually" has that modifier key pressed, thus leading
to pressing eg. `Win+r` instead of just `r`.
2024-01-11 16:00:40 +01:00
Mariusz Bialonczyk
36e79b449d [uwac] input: fix keyboard "sticky" keys when entering window
The commit is fixing the following problem:
When the freerdp window gets keyboard focus and is notified,
it wrongly process keys which are *held*, not a freshly pressed.

The comment in the code explains it more.
2024-01-11 16:00:40 +01:00
akallabeth
f6a208f75e [cmake] generate relative pkgconfig path
generate the relative pkgconfig path from the actual install locations.
fixes #9718
2024-01-05 14:19:34 +01:00