Commit graph

12 commits

Author SHA1 Message Date
Simon Ser
297354f847 Remove unnecessary wl_display_dispatch calls
wl_display_roundtrip already takes care of dispatching the display.
2020-08-24 07:55:35 -06:00
j-n-f
b61a98c417 examples: fix improper use of free
Closes #2303
2020-07-06 00:40:14 +02:00
Simon Ser
16e5e9541b Add -Wmissing-prototypes
This requires functions without a prototype definition to be static.
This allows to detect dead code, export less symbols and put shared
functions in headers.
2019-11-20 02:05:03 +00:00
emersion
a4eb90315e
Fix indentation in various files 2019-01-21 17:56:19 +01:00
emersion
a8bc8c65ce
examples: only link clients to wlroots if necessary 2018-11-06 08:29:30 +01:00
random human
de16defb21
Release registry pointer in examples/idle 2018-09-03 03:27:56 +05:30
random human
8589ae19de Fix bugs listed by clang's static analyzer
A few pedantic changes and unused variables (1-4), and genuine bugs (5,
6).

The reports with the corresponding files and lines numbers are as
follows.

1. backend/libinput/tablet_pad.c@31,44,57
"Allocator sizeof operand mismatch"
"Result of 'calloc' is converted to a pointer of type 'unsigned int',
which is incompatible with sizeof operand type 'int'"

2. types/tablet_v2/wlr_tablet_v2_pad.c@371
"Allocator sizeof operand mismatch"
"Result of 'calloc' is converted to a pointer of type 'uint32_t', which
is incompatible with sizeof operand type 'int'"

3. types/wlr_cursor.c@335
"Dead initialization"
"Value stored to 'dx'/'dy' during its initialization is never read"

4. rootston/xdg_shell.c@510
"Dead initialization"
"Value stored to 'desktop' during its initialization is never read"

5. types/tablet_v2/wlr_tablet_v2_pad.c@475
"Dereference of null pointer"
"Access to field 'strips' results in a dereference of a null pointer
(loaded from field 'current_client')"

The boolean logic was incorrect (c.f. the check in the following
function).

6. examples/idle.c@163,174,182
"Uninitialized argument value"
"1st function call argument is an uninitialized value"

If close_timeout != 0, but simulate_activity_timeout >= close_timeout,
the program would segfault at pthread_cancel(t1).
2018-08-31 19:41:18 +02:00
emersion
7cbef15206
util: add wlr_ prefix to log symbols 2018-07-09 22:49:54 +01:00
emersion
c41de2d1be
render: split render.h into wlr_renderer.h and wlr_texture.h 2018-03-19 23:16:29 +01:00
Dominique Martinet
d1b28ec812 wayland protocol headers: use double-quote for includes
These headers are not installed so we should look for these locally
2018-02-15 07:17:02 +01:00
Timidger
264ef0c261
Fixed logging for examples 2018-01-15 22:51:00 -05:00
Heghedus Razvan
9e85283f06 Add example for idle protocol
Signed-off-by: Heghedus Razvan <heghedus.razvan@gmail.com>
2018-01-13 17:32:15 +02:00