2016-05-11 22:36:12 +02:00
---
title: Tunables
---
2016-07-21 15:30:01 +01:00
- `MG_MALLOC` , `MG_CALLOC` , `MG_REALLOC` , `MG_FREE` allow you to a use custom
2016-05-11 22:36:12 +02:00
memory allocator, e.g. `-DMG_MALLOC=my_malloc`
- `MG_USE_READ_WRITE` when set replaces calls to `recv` with `read` and `send` with `write` ,
thus enabling to add any kind of file descriptor (files, serial devices) to an event manager.
- `MG_SSL_CRYPTO_MODERN` , `MG_SSL_CRYPTO_OLD` - choose either "Modern" or "Old" ciphers
instead of the default "Intermediate" setting.
See [this article ](https://wiki.mozilla.org/Security/Server_Side_TLS#Recommended_configurations ) for details.
2017-03-01 09:50:46 +00:00
- `MG_USER_FILE_FUNCTIONS` allow you to use custom file operation, by defining you own `mg_stat` , `mg_fopen` , `mg_open` , `mg_fread` and `mg_fwrite` functions