Skip to content

Instantly share code, notes, and snippets.

#include <stdio.h> // standard in-out
#include <errno.h> // error message
#include <unistd.h> // close function
#include <string.h>
#include <sys/socket.h> // socket
#include <netinet/in.h> // network address
#include <arpa/inet.h> // convert port number
int main(int argc, char **argv){
@Silica163
Silica163 / main.c
Last active May 19, 2025 11:40
c without stdlib and libc
void exit(int code);
int write(int fd, const void * buff, int count);
int strlen(char * str){
char * end = str;
while(*(end++));
return end - str;
}
int main(int argc, char ** argv, char ** envp){
#!/usr/bin/bash
qemu-system-i386 \
-L pc-bios -nodefaults \
-M pc,accel=tcg,hpet=no -cpu qemu32 \
-m 1024 \
-drive file=./winxp.qcow2,index=0,media=disk,format=qcow2 \
-device VGA \
-cdrom iso/windows-xp.iso \
-boot menu=on
@Silica163
Silica163 / librespot-frontend.html
Last active September 25, 2025 10:04
Frontend for go-librespot in **single** html file.
<!doctype html>
<html>
<head>
<title>go-librespot controller</title>
<style>
html {
width: 40em;
margin:auto;
}
section {