Commit Graph

27 Commits

Author SHA1 Message Date
Armin Novak
5c510af477 [c23,freerdp] replace NULL with nullptr 2026-02-26 15:06:27 +01:00
Armin Novak
48267edf2f [winpr] add WINPR_C_ARRAY_INIT
since C23 allows c++ style initializing replace direct use with this
macro
2026-02-25 19:23:08 +01:00
akallabeth
762eafb76f [c,printf] fix wlog format string to match arguments 2026-01-16 11:41:12 +01:00
Armin Novak
164dfef442 [warnings] fix signed/unsigned compare warnings 2026-01-09 09:24:19 +01:00
Armin Novak
c607056f93 [clang,warnings] fix Wjump-misses-init 2026-01-08 11:32:37 +01:00
akallabeth
ed90a55adf [core] fix BIO_puts implementations
* return -2 if not implemented
* add length sanitizion checks
2025-09-01 09:03:10 +02:00
poasun
036ccd1cdd [core,childsession] fix BIO_set_handle
* Set the HANDLE directly, not a HANDLE*
* Fix the setter function (wrong function signature)
2025-03-31 09:03:44 +02:00
akallabeth
323c6da940 [core] fix warnings and invalid return type 2025-02-13 14:43:31 +01:00
akallabeth
cc934795e4 [warnings] fix integer casting
* use asserting casts to detect overflows or sign conversions
* code cleanup for issues uncovered by casts
2025-01-01 12:58:34 +01:00
akallabeth
83f2f21ad3 [warnigns] fix lots of bugprone warnings
* update-settings-tests: properly cast types in getter/setter
* wtypes: fix PHANDLE definition
* wStream: fix INT64 write function warnings
* Simplify HANDLE copy in channels, just assign after proper cast
2024-12-06 09:15:48 +01:00
akallabeth
fe8e1950aa [warnings] fix integer narrowing 2024-10-03 21:21:21 +02:00
akallabeth
965d231e49 [return checks] fix use of CloseHandle 2024-09-16 08:22:31 +02:00
akallabeth
cd18dea174 [return checks] fix use of unicode functions 2024-09-16 06:48:26 +02:00
akallabeth
384cd284d8 [warnings] use WINPR_CAST_CONST_AWAY
on locations that require (ugly) const to non const casts usw
WINPR_CAST_CONST_AWAY to do proper compiler specific casts to avoid
warnings
2024-09-11 23:41:50 +02:00
akallabeth
6a1c3b4545 [function pointer] use macro for GetProcAddress
Cast all results of GetProcAddress with WINPR_FUNC_PTR_CAST
2024-09-04 21:31:48 +02:00
akallabeth
245afb706c [function pointers] unify casts with macro 2024-09-04 20:06:45 +02:00
akallabeth
baa70d1ab6 [warnings] fix compare integers of different signs 2024-09-03 15:10:46 +02:00
akallabeth
190929c018 [warnings] fix function pointer casts 2024-08-30 15:40:01 +02:00
Armin Novak
7eeaabad8b [core,childsession] initialize variables 2024-06-05 15:57:46 +02:00
David Fort
64b42be79e [win32,chilsession] fix path computation in 32 bits
The path was not adjusted correctly (wrong WCHAR pointer computation).
2024-03-19 10:18:28 +01:00
David Fort
a4cc020b75 [win32,childsession] Fix invalid pipe path with 32 bits builds
When compiled as x86 (32 bits) the path returned by WinStationCreateChildSessionTransport
is sometime missing the beginning of the pipe path.
2024-03-11 11:24:24 +01:00
David Fort
b5713c46a7 [win32] various fix for childSession
WAIT_TIMEOUT was not correctly handled in non blocking mode. Also there was a
segfault when freeing the transport (double free).
2024-03-09 11:29:08 +01:00
David Fort
aebe9742e0 [client,win32] Child session fixes
It seems like WaitFor[Single|Multiple]Object calls aren't reliable on pipes, especially
on the pipe opened for childSession access. The object can be marked as signaled even if
no data is available, making the connection laggy and unresponsive (nearly unusable in some
cases).
This patch works around that by using ReadFileEx() with overlapped instead of simple
ReadFile() and use asynchronous reads.
2024-03-01 09:46:53 +01:00
akallabeth
0ba995655d [clang-tidy] cppcoreguidelines-init-variables 2024-02-15 11:49:16 +01:00
akallabeth
ceb7bd1d41 [warnings] fixed clang build warnings 2023-11-24 18:19:03 +01:00
Armin Novak
07543a6042 [warnings] fix various warnings
* missing const in casts
* missing static for functions
* missing WINPR_ATTR_FORMAT_ARG for printf like functions
2023-10-16 15:10:13 +02:00
David Fort
3c18a9980f [client,win32] implement connection to child session
Under windows you can connect to a child session by requesting a named pipe to
the local server, and then do some RDP on this named pipe.
The protocol is like for /vmconnect with CredSSP, then Nego and then the "normal"
workflow for a connection. For CredSSP we force the usage of NTLM for the Negociate
SSPI, and the credentials are empty.
2023-09-27 11:57:49 +02:00