mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-21 21:05:50 +12:00
Rename test folder & update gitignore
This commit is contained in:
parent
912405b99e
commit
818ade660d
6 changed files with 5 additions and 0 deletions
20
tests/HelloWorldSVC/source/main.c
Normal file
20
tests/HelloWorldSVC/source/main.c
Normal file
|
@ -0,0 +1,20 @@
|
|||
#include <3ds.h>
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
int main(int argc, char** argv) {
|
||||
// Put the string on the heap to make sure heap initialization works
|
||||
const char* buffer = calloc(6969, sizeof(char));
|
||||
strcpy(buffer, "Hello world\n");
|
||||
|
||||
svcOutputDebugString(buffer, strlen(buffer));
|
||||
|
||||
// I hate C's UB rules around infinite loops
|
||||
while (true) {
|
||||
__asm__ volatile ("" ::: "memory");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue