mirror of https://github.com/Genymobile/scrcpy
Fix MIN/MAX macros
Expressions like "x < MAX(y, z)" were broken.
This commit is contained in:
parent
3c3c07db05
commit
389dd77b50
|
@ -5,8 +5,8 @@
|
|||
#include "compat.h"
|
||||
|
||||
#define ARRAY_LEN(a) (sizeof(a) / sizeof(a[0]))
|
||||
#define MIN(X,Y) (X) < (Y) ? (X) : (Y)
|
||||
#define MAX(X,Y) (X) > (Y) ? (X) : (Y)
|
||||
#define MIN(X,Y) ((X) < (Y) ? (X) : (Y))
|
||||
#define MAX(X,Y) ((X) > (Y) ? (X) : (Y))
|
||||
#define CLAMP(V,X,Y) MIN( MAX((V),(X)), (Y) )
|
||||
|
||||
#define container_of(ptr, type, member) \
|
||||
|
|
Loading…
Reference in New Issue