| 11 | static int cfguRefCount; |
| 12 | |
| 13 | Result cfguInit(void) |
| 14 | { |
| 15 | Result ret; |
| 16 | |
| 17 | if (AtomicPostIncrement(&cfguRefCount)) return 0; |
| 18 | |
| 19 | // cfg:i has the most commands, then cfg:s, then cfg:u |
| 20 | ret = srvGetServiceHandle(&cfguHandle, "cfg:i"); |
| 21 | if(R_FAILED(ret)) ret = srvGetServiceHandle(&cfguHandle, "cfg:s"); |
| 22 | if(R_FAILED(ret)) ret = srvGetServiceHandle(&cfguHandle, "cfg:u"); |
| 23 | if(R_FAILED(ret)) AtomicDecrement(&cfguRefCount); |
| 24 | |
| 25 | return ret; |
| 26 | } |
| 27 | |
| 28 | void cfguExit(void) |
| 29 | { |
no test coverage detected