Commit Graph

1968 Commits

Author SHA1 Message Date
Norbert Federa 1eff1a345e free can handle NULL perfectly fine 2015-05-11 09:07:39 +02:00
Hardening a88adcbb7e Merge pull request #2601 from nfedera/fix-2015-05-07-01
Fix some unchecked create calls
2015-05-07 19:06:59 +02:00
Norbert Federa b2dcde35ee Merge pull request #2599 from hardening/fix_wayland_colors
Fix colors with the wayland client
2015-05-07 18:15:01 +02:00
David FORT 0e2925d0b8 Fix remoteApps
The assert that have been removed were preventing RAIL from working when you
have an intermediary screen before seeing the application.
2015-05-07 14:36:07 +02:00
Norbert Federa e3fb908686 Fix unchecked CreateSemaphore calls 2015-05-07 13:28:03 +02:00
David FORT b09f6bedb7 Fix colors with the wayland client 2015-05-06 21:54:39 +02:00
Norbert Federa 25fc866a58 Fix unchecked CreateThread calls and misc fixes 2015-05-05 13:55:48 +02:00
Norbert Federa ef1fd12b15 Fix unchecked CreateEvent calls and misc fixes
1)
Added missing checks for CreateEvent which also required the
following related changes:

- changed freerdp_context_new API to BOOL
- changed freerdp_peer_context_new API to BOOL
- changed pRdpClientNew callback to BOOL
- changed pContextNew callback to BOOL
- changed psPeerAccepted callback to BOOL
- changed psPeerContextNew callback to BOOL

2)
Fixed lots of missing alloc and error checks in the
changed code's neighbourhood.

3)
Check freerdp_client_codecs_prepare result to avoid segfaults
caused by using non-initialized codecs.

4)
Fixed deadlocks in x11 caused by missing xf_unlock_x11() calls
in some error handlers

5)
Some fixes in thread pool:
- DEFAULT_POOL assignment did not match TP_POOL definition
- don't free the pool pointer if it points to the static DEFAULT_POOL
- added error handling and cleanup in InitializeThreadpool
2015-04-29 18:18:39 +02:00
Marc-André Moreau 1fea6bf702 Merge pull request #2568 from nfedera/fix-2015-04-23-01
codec/rfx: error checking and various fixes
2015-04-24 13:36:27 -04:00
Bryan Everly 18b335e2f2 Added support for manpage construction for OpenBSD 2015-04-24 08:38:35 -04:00
Norbert Federa 84577b1ca7 codec/rfx: error checking and various fixes
- removed some unneeded null checks for free()
- fixed a memory leak in shadow_client
- removed rfx_compose_message_header from API

Changed the following functions to BOOL, check the result
where they are called and handle failures:
- rfx_compose_message
- rfx_compose_message_header
- rfx_write_tile
- rfx_write_message_tileset
- rfx_write_message_frame_begin
- rfx_write_message_region
- rfx_write_message_frame_end
- rfx_write_message

rfx_process_message:
- check memory allocation failures
- verify protocol-conform order of data messages to prevents memory
  leaks caused by repeated allocations
- verify that header messages were parsed/received before the
  data messages
- treat unknown rlgr mode as error
- fixed/added error handling
- fixed all callers to check/handle result

rfx_encode_message:
- fixed incorrect usage of realloc
- missing malloc check
- missing check of CreateThreadpoolWork
- correct cleanup on failure (threadpool, memory)
- check rfx_encode_message result

rfx_encode_messages:
- check rfx_split_message result
- correct cleanup on failure
- prevent memory leak on failure

rfx_write_message_context:
- fixed invalid channelId value (must be 0xFF for WBT_CONTEXT)

rfx_process_message_codec_versions:
- fixed invalid read size of codec_version (it is 16bit)

rfx_process_message_channels:
- verify protocol conform channelId value

rfx_process_message_region:
- replaced invalid reallocs with malloc
- read and verify regionType and numTileSets from stream

rfx_process_message_tileset:
- check allocation results
- fixed incorrect usages of realloc

setupWorkers:
- fixed incorrect usages of realloc

rfx_split_message:
- removed dead code
- missing malloc check

rfx_compose_message:
- fixed a memory leak
- check/handle rfx_encode_message result
2015-04-23 15:42:21 +02:00
Armin Novak 7524ea53c6 Updated to new freerdp_get_event_handles API. 2015-04-22 11:17:47 +02:00
Armin Novak a07d1c4b97 Updated wayland client to new API. 2015-04-22 11:16:41 +02:00
Hardening 6cd7713e12 Merge pull request #2544 from bmiklautz/boolenization
change return types of callbacks to BOOL
2015-04-22 11:01:27 +02:00
Bryan Everly 8c75127a67 Necessary changes to get latest branch working on OpenBSD 5.6 2015-04-21 14:42:06 -04:00
Bernhard Miklautz 1e6943bf31 Fix formating 2015-04-21 14:20:24 +02:00
Bernhard Miklautz db81151ea4 gdi: fix broken return type checks
Integrates comments from pull request.
2015-04-21 14:18:07 +02:00
Bernhard Miklautz 2c072d33d3 Fix GDI return values and other fixes
* top level GDI functions return 0 on error and != 0 otherwise but the
  low level functions (16bpp.c, 8bpp.c 32bpp.c) which are called did it
	exactly the other way around. Those were adapted.
* change gdi_InvalidateRegion to BOOL and check calls where appropriate
* integrate comments from pull request
2015-04-21 14:18:07 +02:00
Bernhard Miklautz 515502ffa5 change return types of callbacks to BOOL
* change all client/server callbacks to BOOL
* update all clients accordingly
* add multiple return value checks
* small fixes
2015-04-21 14:18:07 +02:00
Bernhard Miklautz 43695bc15d ios: updates to build with xcode6+
* update tool chain to use clang instead of gcc
* add compatibility function for fwrite
2015-04-21 14:16:32 +02:00
Armin Novak d3336340ba Add *get_event_handles handle count, return check. 2015-04-21 12:24:50 +02:00
Bernhard Miklautz 5622b911cb Merge pull request #2552 from akallabeth/sample_update
Sample update
2015-04-20 17:47:44 +02:00
Armin Novak 70cf129c55 Moved cleanup code, removed unused. 2015-04-19 10:39:08 +02:00
Armin Novak efeb621721 Updated sample for new API. 2015-04-19 10:39:08 +02:00
Norbert Federa fd5f47428b xfreerdp: fixed initial smart-sizing dimensions
The window width/height variables and in turn SmartSizingWidth/Height
get automatically updated in th the configure notify event handler.
If the window is created initially the values don't differ from the
event values and therefore SmartSizing was not applied until the
window was resized.
2015-04-16 23:54:56 +02:00
Norbert Federa bad2f138c1 xfreerdp: FS fixes & smart-sizing resuscitation
- make smart-sizing work again which was killed in previous commits
- removed several unnecessary/ugly workarounds
- miscellaneous small fixes
- new feature: restore previous window position when toggling out of
  fullscreen mode
- new feature: if /f is specified in combination with /smart-sizing:WxH
  we run the session in the /smart-sizing dimensions scaled to full screen
2015-04-16 17:31:22 +02:00
Norbert Federa eb14ab15f5 xfreerdp: removed some weird/unnecessary code 2015-04-16 17:31:22 +02:00
Norbert Federa 98505a0234 xfreerdp: removed desktopWidth/desktopHeight vars
These were basically unused (from the contexts's point of view)
and only served as temporary storage
2015-04-16 17:31:22 +02:00
Norbert Federa b3b8306724 xfreerdp: removed unused variables from xf_monitor 2015-04-16 17:31:22 +02:00
Norbert Federa 6354a7561c xfreerdp: rename xf_context's width height vars
Since several contributers in the past repeatedly made the error
to treat xfc->width and xfc->height as equal with the x11 window
width and heigth I've renamed these variables to sessionWidth and
sessionHeight.
2015-04-16 17:31:22 +02:00
Bernhard Miklautz 0615c13dbb Fix regression introduced in 0b7f9d4
This fixes problems with command line parsing.
2015-04-02 22:53:45 +02:00
Armin Novak 878aecfa48 Fixed conversion warnings. 2015-03-31 15:18:45 +02:00
Bernhard Miklautz 3c7662517c hardening
Start to add missing checks for:
* *alloc
* *_New
2015-03-25 17:38:21 +01:00
Armin Novak 47f38b3059 Fixed uninitialized test argument buffer. 2015-03-23 14:14:38 +01:00
Marc-André Moreau 6202f48c12 libfreerdp-core: add configurable TSG/RGB fallback, fix edge cases 2015-03-19 11:44:47 -04:00
Marc-André Moreau 4faf8010b7 Merge pull request #2478 from akallabeth/win_sw_gdi_fix
Fixed resize for software GDI.
2015-03-19 09:35:31 -04:00
Armin Novak f3d6a791e7 Fixed resize for software GDI. 2015-03-17 13:03:16 +01:00
Marc-André Moreau 2094501d8b freerdp: fix failing tests 2015-03-16 09:26:38 -04:00
Marc-André Moreau c21bff5415 Merge branch 'master' of github.com:FreeRDP/FreeRDP 2015-03-16 08:01:54 -04:00
Armin Novak b39940e0a5 Added ignore unkown keyword flag to detection. 2015-03-16 10:25:31 +01:00
Armin Novak c380fb3520 Added flag to ignore unknown keywords
freerdp_client_settings_parse_command_line now allows ignoring
unknown keywords.
2015-03-16 10:15:37 +01:00
Marc-André Moreau afdd55fa81 Merge branch 'master' of github.com:FreeRDP/FreeRDP 2015-03-13 15:30:31 -04:00
Marc-André Moreau cb27703d2e Merge pull request #2461 from ivan-83/master
audin OSS support, dyn channels fix, dev arg broken fix, add debug verbosity, build warning fix
2015-03-13 15:19:35 -04:00
Zhang Zhaolong 5b2a8ee873 wr_cliprdr: fix uninitialized variable
Signed-off-by: Zhang Zhaolong <zhangzl2013@126.com>
2015-03-13 10:32:21 +08:00
ivan-83 9e7e4ce7ff Merge branch 'master' of github.com:ivan-83/FreeRDP 2015-03-13 01:39:41 +03:00
ivan-83 7b3a552988 + audin OSS support (un tested now)
+ add: COMMAND_LINE_IGN_UNKNOWN_KEYWORD flag for CommandLineParseArgumentsA to ignory unknown keys without fail
+ add: lot of WLog_DBG() in drdynvc, add function names in existing
* change: error text in rdpsnd OSS
* fix: dev in rdpsnd does not work
* fix/change: audio-dev renamed to dev and now work in audin
* fix dynamic channels now work again
2015-03-13 01:28:44 +03:00
Marc-André Moreau 5ab34dfa3e Merge pull request #2456 from zhangzl2013/fix-realloc
Fix incorrect usage of realloc
2015-03-12 07:33:27 -04:00
Marc-André Moreau 0e339786e6 Merge pull request #2452 from bmiklautz/cmd_fix
settings: handle collection_add in detection case
2015-03-12 07:31:11 -04:00
Marc-André Moreau 719a0fd3e9 Merge pull request #2426 from bjcollins/master
xfreerdp fullscreen enhancements
2015-03-12 07:27:29 -04:00
Marc-André Moreau cd569ca833 Merge pull request #2430 from serayrosh/master
release keys when xfreerdp is unfocused to prevent stuck keys
2015-03-12 07:25:00 -04:00