Rewrite a simple "option-name " configuration option. */
| 1531 | |
| 1532 | /* Rewrite a simple "option-name <bytes>" configuration option. */ |
| 1533 | void rewriteConfigBytesOption(struct rewriteConfigState *state, const char *option, long long value, long long defvalue) { |
| 1534 | char buf[64]; |
| 1535 | int force = value != defvalue; |
| 1536 | sds line; |
| 1537 | |
| 1538 | rewriteConfigFormatMemory(buf,sizeof(buf),value); |
| 1539 | line = sdscatprintf(sdsempty(),"%s %s",option,buf); |
| 1540 | rewriteConfigRewriteLine(state,option,line,force); |
| 1541 | } |
| 1542 | |
| 1543 | /* Rewrite a yes/no option. */ |
| 1544 | void rewriteConfigYesNoOption(struct rewriteConfigState *state, const char *option, int value, int defvalue) { |
no test coverage detected