Commit Graph

349 Commits

Author SHA1 Message Date
Alexandru Bagu
a8cc80851f fixes argument order for rdpdr_load_drive 2021-10-22 09:31:25 +02:00
Armin Novak
6e410e6dd4 Fixed broken message queue free function 2021-10-18 12:49:38 +02:00
Armin Novak
7d80c74e97 Cleaned up RDPDR channel interhitance
* All channels inheriting from RDPDR_DRIVE base struct
* Add functions to create/free a new device of a type
* Fixed settings array resize code, prevent 0 sizes
2021-10-18 09:21:02 +02:00
akallabeth
e0a531f728
Channel fixes (#7309)
* Added missing CHANNEL_NAME defines.

* Fixed FreeRDP_ChannelDefArray setter

* Fixed code duplication due to merge error

* Added public function freerdp_channels_from_mcs

* Fixed const correctness in mcs
2021-09-22 14:27:21 +02:00
akallabeth
a3a935283b Fixed invalid read in rdpdr 2021-09-20 10:59:59 +02:00
Armin Novak
0fe1e2359e Fixed all reserved-id-macro warnings 2021-09-10 08:16:25 +02:00
Armin Novak
95ecc6929a Refactored channel error handling
* Fix WINPR_ASSERT if a client can not allocate new resources,
  terminated cleanly instead.
* Add WINPR_ASSERT for lots of channel arguments
2021-09-09 08:53:20 +02:00
Armin Novak
467f7c3f6a Fixed proxy ulimit graceful client disconnect 2021-09-09 08:53:20 +02:00
Armin Novak
275f9ab2f6 Added listforeach wrapper 2021-07-29 15:09:53 +02:00
Armin Novak
4e3a7562af Clarified log message for device redirection 2021-07-29 15:09:53 +02:00
Armin Novak
da57b0b91b Fixed resource cleanup 2021-07-29 15:09:53 +02:00
Armin Novak
55592049dc WINPR_ASSERT for drive redirection 2021-07-29 15:09:53 +02:00
Armin Novak
a788145519 Fixed wrong error message 2021-07-29 15:09:53 +02:00
Martin Fleisz
6ecdd82e28 rdpdr: Fix length calculation for client name response 2021-07-07 11:48:56 +02:00
Armin Novak
8276c145e0 Fixed rdpdr related warnings 2021-06-18 11:32:16 +02:00
Armin Novak
c4c5847f81 channels: Fixed warnings, added assertions 2021-06-18 11:32:16 +02:00
Armin Novak
ccfe0c129e Removed checks already done by WINPR_ASSERT 2021-06-16 11:46:42 +02:00
Biswapriyo Nath
4c9754b269 Read from QuadPart from LARGE_INTEGER variables. 2021-05-31 13:38:19 +02:00
Armin Novak
d039a1ac8f Filter RDPDR types other than drives on windows hotplug 2021-03-09 13:58:28 +01:00
sss
6574fdf6e4 reverted changes from clang-format 2021-02-25 14:05:40 +01:00
Gluzskiy Alexandr
bee2e1526d allow to use in single threaded mode
(some client side channels and all server side channels still need to be
ported to new api)

server: build fix, do not disable threads for rfx encoder

cliprdr client channel: implemented support for DisableThreads option
looks like thread does not make sense at all for this channel

do not initialize disabled image codecs (respect settings)

channels: client: rail: added support for DisableThreads setting

changed "BOOL DisableThreads" to "UINT32 ThreadingFlags"
dropped unnecessary apu changes

draft implementation of threading settings aware message handling api
for addins/channels

rail: use new messaging api

fixed memory leak

msgs handlers external api changes (as requested)

msgs_handlers: init fix

fixed memory leak

logic fix

resolved problems appeared after rebase to master, dropped unnecessary
changes

git clang-format origin/master

fixed TestFreeRDPCodecRemoteFX.c

"formatting, run `clang-format` please"

properly use new "rfx_context_new(BOOL, UINT32)" everywhere

passed Threading Flags to "rfx_context_new" where available

in older C standarts veriables declaration must be done before any code

requested changes

clang-format as requested

use broken signatures of standert C functions for m$ s**tos

clang-format

requested changes

requested changes

moved ThreadingFlags to stable api zone

define type for channel msg handler

typo fix

clang-format

build fix

us ThreadingFlags from server settings

git clang-format origin/master

clang-format
2021-02-25 14:05:40 +01:00
Armin Novak
c7bf33aad0 Fixed drive hotplug path comparison. 2021-01-27 09:27:08 +01:00
akallabeth
9e8d3fbbf5 Check drive to hotplug for already being redirected
some hotplug implementations report the same drive multiple times.
to avoid redirecting the same drive multiple times check if it is
already in the list before adding.
2021-01-15 10:41:12 +01:00
Martin Fleisz
c78e31e451 channel/rdpdr: Fix hotplug for drive redirection on Windows
The path was incorrectly cut of after the drive letter causing hot
plugged drives to show up empty and disconnecting the client if the
device was removed later on.
2020-11-13 12:26:29 +01:00
akallabeth
66dc4cc9ee Fixed compilation warnings. 2020-11-10 08:53:43 +01:00
akallabeth
6e3c00725a Cleaned up collections:
ArrayList, MessageQueue, Queue, PubSub, BipBuffer
ObjectPool and BufferPool
2020-11-06 12:30:13 +01:00
akallabeth
6e5f5de439 Do not abort disc hotplug if no access to mount tab. 2020-10-27 15:45:56 +01:00
Alexandr
616af2d5b8
fixed build on freebsd (#6395)
* fixed build on freebsd
2020-07-27 11:36:24 +02:00
Marco van Wieringen
9db147c317 Add support for getmntent support on Illumos
This implements reading mount entries on Solarish operating systems like
OpenIndiana etc using the somewhat different getmntent support available
there.
2020-07-24 09:16:46 +02:00
akallabeth
b971c5c97f Use CMake to detect availability of getlogin_r 2020-07-01 16:50:20 +02:00
akallabeth
caff01877d Fixed fallback to getlogin for android 2020-06-22 12:09:36 +02:00
akallabeth
1c6a6923f8 Fixed broken const variable. 2020-06-22 11:51:39 +02:00
akallabeth
36478d3d0b Replaced getlogin with getlogin_r 2020-06-22 11:51:38 +02:00
qarmin
fe8bad1698 Don't allow to overflow dev_array array 2020-05-01 20:34:59 +02:00
Armin Novak
451c4ddee6 Passing on error code from irp_free 2020-02-21 11:31:21 +01:00
Armin Novak
30db616cec Added a free function to erase streams not processed.
When shutting down the streams still in the queue were not properly
freed.
2020-02-21 11:31:15 +01:00
Armin Novak
436b68e416 Fixed #5895: cast warnings. 2020-02-19 10:21:43 +01:00
Armin Novak
d2aef75004 Fix #5852: handle CHANNEL_EVENT_WRITE_CANCELLED
When channels are cleaned up OpenHandle is most of the time
already 0. Ignore the argument checks for
CHANNEL_EVENT_WRITE_CANCELLED and CHANNEL_EVENT_WRITE_COMPLETE
only check where actually required (CHANNEL_EVENT_DATA_RECEIVED)
2020-01-29 08:52:25 +01:00
Armin Novak
ac553e1bb5 Fix #5805: windows hotplug drive detection. 2020-01-07 10:35:12 +01:00
ajlex140
2f2f4f91d8 reply with empty irp package with error code, if irp device is unavailable 2019-12-09 11:43:02 +01:00
Armin Novak
9f3adf10f8 Fixed #5727: use getmntent to read /proc/mounts 2019-11-18 15:25:18 +01:00
Armin Novak
72ca88f49c Reformatted to new style 2019-11-07 10:53:54 +01:00
Armin Novak
75ed12f1f0 Fixed userdata pointer and CHANNEL_EVENT_WRITE_CANCELLED message. 2019-11-06 13:01:43 +01:00
Armin Novak
1bcb799560 Listen to CHANNEL_EVENT_WRITE_CANCELLED and emit if queue is cleared. 2019-11-06 13:01:43 +01:00
Armin Novak
1b78b59926 Fixed #4809: Properly process CHANNEL_EVENT_WRITE_COMPLETE 2019-11-06 13:01:43 +01:00
Armin Novak
09d14a2462 Fixed VirtualChannelWriteEx error case leaks. 2019-11-06 13:01:43 +01:00
Armin Novak
64f64cd035 devman_load_device_service device argument can be const. 2019-10-24 15:04:48 +02:00
Armin Novak
5e9f454256 Use stat instead of lstat to iterate /Volumes
Some entries are symbolic links, so follow them and check the link
target for being a directory.
2019-09-12 14:35:01 +02:00
Armin Novak
6f82ab6204 Hotplugging only for drive redirection. 2019-09-12 11:14:39 +02:00
Armin Novak
15bc118d78 Names of services are now const. 2019-09-04 15:48:34 +02:00