Commit Graph

19 Commits

Author SHA1 Message Date
Armin Novak
b724ba546d [checks,return] fix various unchecked return values 2026-03-03 09:40:27 +01:00
Armin Novak
e6fca2c021 [winpr,stream] Fix Stream_SetPosition return checks 2026-03-02 11:37:20 +01:00
Armin Novak
fc6f76d23b [server,proxy] expect element to be NULL
channel_stop_and_wait might be called with incompletely allocated
elements. Assume each member of the struct might be NULL
2026-03-02 09:57:03 +01:00
Armin Novak
cc5f1bbb82 [server,proxy] check for nullptr before using scard_call_context
* Make smartcard_call_cancel_all_context return FALSE if a NULL context
  is supplied.

* Do not call smartcard_call_context_signal_stop if the context is NULL
2026-03-02 09:45:27 +01:00
Armin Novak
92ab55c5e1 [winpr,stream] Add Stream_ResetPosition
A helper function that does not require return checks, in contrast to
Stream_SetPosition, which might fail.
2026-03-01 06:11:59 +01:00
Armin Novak
e5816d65ce [c23,server] replace NULL with nullptr 2026-02-26 14:34:11 +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
6598081863 Merge pull request #12326 from akallabeth/server-attr-nodiscard
[server] add WINPR_ATTR_NODISCARD macro
2026-02-24 11:16:27 +01:00
akallabeth
b2f325251a [server] add WINPR_ATTR_NODISCARD macro 2026-02-24 11:03:46 +01:00
Armin Novak
e6172762aa [server,proxy] use default threadpool
Do not create a threadpool per smartcard channel instance. This is
overkill and does not really improve performance, just wastes resources.
2026-02-20 11:02:34 +01:00
akallabeth
8bd7814e9a [server,proxy] Log MinorFunction in smartcard channel 2025-03-05 23:48:56 +01:00
akallabeth
4df9e30604 [proxy,channels] fix return values and sign conversions 2025-02-13 15:35:15 +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
Armin Novak
641022b795 [logging] remove __FUNCTION__ from actual message
prefer the log formatter to provide that information.
2023-01-25 16:26:39 +01:00
Armin Novak
b614a2da37 [server,proxy] improve rdpdr channel logging 2022-12-22 15:09:03 +01:00
Martin Fleisz
8a06ed9299 proxy: Reset stream position before length check 2022-05-19 09:23:32 +02:00
akallabeth
73cdcdfe09 Logging and parser fixes (#7796)
* Fixed remdesk settings pointer

* Fixed sign warnings in display_write_monitor_layout_pdu

* Use freerdp_abort_connect_context and freerdp_shall_disconnect_context

* Added and updates settings

* info assert/dynamic timezone

* mcs assert/log/flags

* Fixed and added assertions for wStream

* Unified stream length checks

* Added new function to check for lenght and log
* Replace all usages with this new function

* Cleaned up PER, added parser logging

* Cleaned up BER, added parser logging

* log messages

* Modified Stream_CheckAndLogRequiredLengthEx

* Allow custom format and options
* Add Stream_CheckAndLogRequiredLengthExVa for prepared va_list

* Improved Stream_CheckAndLogRequiredLength

* Now have log level adjustable
* Added function equivalents for existing logger
* Added a backtrace in case of a failure is detected

* Fixed public API input checks
2022-04-19 14:29:17 +02:00
Armin Novak
4e6e5be654 Added proxy intercept channels
* New configuration to intercept certain channels
* Added rdpdr intercept implementation
2022-01-11 12:34:43 +01:00