| 2251 | } |
| 2252 | |
| 2253 | static int updateMaxmemory(long long val, long long prev, const char **err) { |
| 2254 | UNUSED(prev); |
| 2255 | UNUSED(err); |
| 2256 | if (val) { |
| 2257 | size_t used = zmalloc_used_memory()-freeMemoryGetNotCountedMemory(); |
| 2258 | if ((unsigned long long)val < used) { |
| 2259 | serverLog(LL_WARNING,"WARNING: the new maxmemory value set via CONFIG SET (%llu) is smaller than the current memory usage (%zu). This will result in key eviction and/or the inability to accept new write commands depending on the maxmemory-policy.", server.maxmemory, used); |
| 2260 | } |
| 2261 | performEvictions(); |
| 2262 | } |
| 2263 | return 1; |
| 2264 | } |
| 2265 | |
| 2266 | static int updateGoodSlaves(long long val, long long prev, const char **err) { |
| 2267 | UNUSED(val); |
nothing calls this directly
no test coverage detected