Skip to content

Instantly share code, notes, and snippets.

View pudelkoM's full-sized avatar
🚀
Send it

Maximilian Pudelko pudelkoM

🚀
Send it
View GitHub Profile
static void escape(void *obj) {
asm volatile("" : : "g"(obj) : "memory");
}
static void globber() {
asm volatile("" : : : "memory");
}
#include <sys/types.h>
#include <sys/socket.h>
#include <netdb.h>
#ifndef fatal
#define fatal(msg) \
do { fprintf(stderr, "[FATAL]: %s:%i: %s: %s\n", __func__, __LINE__, msg, strerror(errno)); exit(EXIT_FAILURE); } while (0)
#endif
int create_bound_socket(const sa_family_t domain, const int protocol, const char* ip, const char* port) {
@pudelkoM
pudelkoM / conway.py
Last active August 29, 2015 14:21
conway 3d edition
import random
from PyQt5 import QtGui, QtWidgets
import time
from PyQt5.QtCore import Qt, QThread, pyqtSignal, QEvent
import itertools
class OpenGLWindow(QtGui.QWindow):
def __init__(self, parent=None):
super(OpenGLWindow, self).__init__(parent)
#quitAction = QAction("Exit", self, shortcut="Ctrl+Q", triggered=QApplication.instance().quit)
@pudelkoM
pudelkoM / evangelion.py
Last active August 29, 2015 14:17
Emergency hexagons from evangelion
#!/usr/bin/env python3
#Plaster your screen with hexagons! Exit with CTRL+Q
#Requires python3 (probably 3.4) and pyQt5 but is platform independent
#https://www.python.org/downloads/release/python-343/
#http://www.riverbankcomputing.com/software/pyqt/download5
from PyQt5.QtCore import QPoint, QSize, Qt, QTime, QTimer, QPropertyAnimation, QPointF, QThread, pyqtSignal, pyqtSlot
from PyQt5.QtGui import QColor, QPainter, QPolygon, QRegion, QPen, QFont, QPolygonF
@pudelkoM
pudelkoM / kc_ce.user.js
Last active August 29, 2015 14:09
KC catalog enhancement
// ==UserScript==
// @name KC Catalog Search
// @namespace https://gist.github.com/genericname462
// @icon https://krautchan.net/favicon.ico
// @include https://krautchan.net/catalog/*
// @match https://*.krautchan.net/catalog/*
// @updateURL https://gist.github.com/genericname462/ee2cfeb69e5a4c31f48c/raw/kc_ce.user.js
// @downloadURL https://gist.github.com/genericname462/ee2cfeb69e5a4c31f48c/raw/kc_ce.user.js
// @version 0.0.15
// @grant none
@pudelkoM
pudelkoM / navbar.user.js
Last active August 29, 2015 14:08
KC navbar auto updater
// ==UserScript==
// @name KC Auto
// @namespace https://gist.github.com/genericname462
// @description KC navbar updater
// @include https://muelleimer.krautchan.net/*
// @include https://schattengang.krautchan.net/*
// @include https://krautchan.net/*
// @match *.krautchan.net./*
// @version 0.1
// @grant none