Comparison

util-src/pposix.c @ 7966:30309fd01d76

util.pposix: Use correct type for limits [-Wconstant-conversion]
author Kim Alvefur <zash@zash.se>
date Tue, 07 Mar 2017 22:36:43 +0100
parent 7965:57f98394b830
child 7969:1c6a07606309
comparison
equal deleted inserted replaced
7965:57f98394b830 7966:30309fd01d76
540 540
541 #endif 541 #endif
542 return -1; 542 return -1;
543 } 543 }
544 544
545 unsigned long int arg_to_rlimit(lua_State *L, int idx, rlim_t current) { 545 rlim_t arg_to_rlimit(lua_State *L, int idx, rlim_t current) {
546 switch(lua_type(L, idx)) { 546 switch(lua_type(L, idx)) {
547 case LUA_TSTRING: 547 case LUA_TSTRING:
548 548
549 if(strcmp(lua_tostring(L, idx), "unlimited") == 0) { 549 if(strcmp(lua_tostring(L, idx), "unlimited") == 0) {
550 return RLIM_INFINITY; 550 return RLIM_INFINITY;