Exemplo n.º 1
0
int main(int argc, char **argv) {
    unsigned char *dynamic = malloc(8);
    unsigned char stack[8];
    printf("Global:\n");
    test_bits(global);  /* All valid */
    printf("Dynamic:\n");
    test_bits(dynamic); /* Invalid, but probably 0 anyway */
    printf("Stack:\n");
    test_bits(stack);   /* Invalid and likely garbage */
    return 0;
}
Exemplo n.º 2
0
Arquivo: main.c Projeto: handgod/soma
int main(int argc, char *argv[])
{
    printf("test_init...\n");
    test_init();

    printf("test_bits...\n");
    test_bits();

    printf("test_clear...\n");
    test_clear();

    printf("test_modify...\n");
    test_modify();

    printf("test_xor...\n");
    test_xor();

    printf("done.\n");
    return 0;
}