Ejemplo n.º 1
0
Archivo: assert.c Proyecto: esxgx/uofw
void sceKernelAssert(int test, int lvl)
{
    if (test)
        return;
    // CFD0
    if (sceKernelDipsw(8) == 0)
    {
        // D00C
        Kprintf("assertion ignore (level %d)\n", lvl);
        return;
    }
    void (*assertFunc)(int) = g_assertHandler;
    if (assertFunc == NULL)
    {  
        // CFFC
        Kprintf("There is no assert handler, stop\n");
        for (;;) // D004
            ;
    }
    assertFunc(0);
}
void assertPrestige(RoomyGraph *g, uint64 node, uint64 expected) {
  assertFunc(g, node, expected, RoomyGraphAlg_degreePrestige);
}
void assertCentrality(RoomyGraph *g, uint64 node, uint64 expected) {
  assertFunc(g, node, expected, RoomyGraphAlg_degreeCentrality);
}