| 102 | } |
| 103 | |
| 104 | static int |
| 105 | iconv_mod_handler(module_t mod, int type, void *data) |
| 106 | { |
| 107 | int error; |
| 108 | |
| 109 | switch (type) { |
| 110 | case MOD_LOAD: |
| 111 | error = 0; |
| 112 | sx_init(&iconv_lock, "iconv"); |
| 113 | break; |
| 114 | case MOD_UNLOAD: |
| 115 | error = iconv_mod_unload(); |
| 116 | break; |
| 117 | default: |
| 118 | error = EINVAL; |
| 119 | } |
| 120 | return error; |
| 121 | } |
| 122 | |
| 123 | static moduledata_t iconv_mod = { |
| 124 | "iconv", iconv_mod_handler, NULL |
nothing calls this directly
no test coverage detected