Fix more vs warnings

This commit is contained in:
pancake 2021-08-17 00:35:52 +00:00
parent 8a78055996
commit bd888a2edf
4 changed files with 11 additions and 8 deletions

View File

@ -494,8 +494,8 @@ R_API void r_cons_canvas_circle(RConsCanvas *c, int x, int y, int w, int h, cons
double ca = r_num_cos (a);
double cx = s * ca + (size / 2);
double cy = s * sa + (size / 4);
int X = x + (xfactor * cx) - 2;
int Y = y + ((yfactor/2) * cy);
int X = x + (int)(xfactor * cx) - 2;
int Y = y + (int)((yfactor/2) * cy);
if (G (X, Y)) {
W ("=");
}

View File

@ -74,7 +74,7 @@ static ut32 __approximate_rgb(int r, int g, int b) {
b &= 0xff;
return (ut32)((G * M * M) + (g * M) + b) + 16;
#else
const int k = (256.0 / 6);
const int k = (int)(256.0 / 6);
r = R_DIM ((int)(r / k), 0, 6);
g = R_DIM ((int)(g / k), 0, 6);
b = R_DIM ((b / k), 0, 6);

View File

@ -397,7 +397,8 @@ R_API bool r_io_map_resize(RIO *io, ut32 id, ut64 newsize) {
}
ut64 addr = r_io_map_begin (map);
if (UT64_MAX - newsize + 1 < addr) {
r_io_map_set_size (map, -addr);
st64 saddr = (st64)addr;
r_io_map_set_size (map, -saddr);
r_io_map_new (io, map->fd, map->perm, map->delta - addr, 0, newsize + addr);
return true;
}

View File

@ -37,13 +37,15 @@ option('use_sys_openssl', type: 'boolean', value: false)
option('static_sys_openssl', type: 'boolean', value: false)
option('use_libuv', type: 'boolean', value: true)
option('use_fork', type: 'boolean', value: true)
option('sdb_cgen', type: 'boolean', value: true)
option('use_dylink', type: 'boolean', value: true)
option('sdb_cgen', type: 'boolean', value: true) # fails on windows builds -Duse_cgen=false
option('use_dylink', type: 'boolean', value: true)testing
option('debugger', type: 'boolean', value: true)
option('want_ptrace_wrap', type: 'boolean', value: true)
option('want_ptrace_wrap', type: 'booleamd
n', value: true)
option('nogpl', type: 'boolean', value: false)
option('use_webui', type: 'boolean', value: false, description: 'install different WebUIs for radare2')
option('enable_tests', type: 'boolean', value: true, description: 'Build unit tests in test/unit')
option('enable_r2r', type: 'boolean', value: true, description: 'Build r2r executable for regression testing')
option('enable_r2r', type: 'boolean', value: true, description: 'Build r2r executable for regression ')