Skip to content

Instantly share code, notes, and snippets.

View Keruspe's full-sized avatar
🦀
Smashing bugs to outerspace

Marc-Antoine Perennou Keruspe

🦀
Smashing bugs to outerspace
View GitHub Profile
@Keruspe
Keruspe / BackGoto.java
Created October 31, 2010 14:27
ULGY ! Simulate a goto which go back into the code, in Java
package gotopkg;
/**
*
* @author keruspe
*/
public class Main {
public static void main(String[] args) {
Integer loop = 0;
@Keruspe
Keruspe / virtual.cc
Created January 10, 2011 23:04
Simple example of "virtual" usage to explain it to beginners
#include <iostream>
class Foo {
public:
Foo() {}
virtual void speak() {std::cout << "I'm foo" << std::endl;}
void talk() {std::cout << "I'm still foo" << std::endl;}
};
class Bar : public Foo {
public:
Bar() {}
@Keruspe
Keruspe / Ref.java
Created June 27, 2011 12:48
Why I do hate java
public class Ref {
public void inc1(int i) {
++i;
}
public void inc2(Integer i) {
++i;
}
public static void main(String[] args) {
int foo = 32;
Integer bar = 41;
@Keruspe
Keruspe / whatthefloat.c
Created October 18, 2011 17:20
Would this be a bug in the glibc ?
#include <stdio.h>
int
main()
{
float f = 3.5;
int i = 8;
const char *format_previous = "%f";
printf ("This will output the previous float, expecting the good one\n");
printf (format_previous, f);
sydbox@1413380601: ignore unsupported magic value `LOOPBACK6@0'
sydbox@1413380601: ignore unsupported magic value `LOOPBACK6@1024-65535'
sydbox@1413380601: bash[23874.0:4294964307] sys:4|stat| ignore unsupported magic value `LOOPBACK6@0'
sydbox@1413380601: bash[23874.0:4294964307] sys:4|stat| ignore unsupported magic value `LOOPBACK6@1024-65535'
@Keruspe
Keruspe / stdin
Created February 6, 2015 12:31
stdin
foo
@Keruspe
Keruspe / stdin
Created February 12, 2015 14:26
stdin
diff --git a/limits.h b/limits.h
index eaef53d..42049f9 100644
--- a/limits.h
+++ b/limits.h
@@ -57,7 +57,7 @@
* maximum number of queued messages from the same indvidual user after the
* the un-accounted value has been hit
*/
-#define KDBUS_CONN_MAX_MSGS_PER_USER 16
+#define KDBUS_CONN_MAX_MSGS_PER_USER 1024
@Keruspe
Keruspe / stdin
Created February 19, 2015 13:24
stdin
From 67c54ffc7a0e31af19b8cfcc784e203b71a0e07d Mon Sep 17 00:00:00 2001
From: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
Date: Thu, 19 Feb 2015 14:23:54 +0100
Subject: [PATCH] local-display-factory: fix daemon/WaylandEnable
Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
---
daemon/gdm-local-display-factory.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@Keruspe
Keruspe / stdin
Created February 25, 2015 17:35
stdin
-----BEGIN PGP MESSAGE-----
Version: GnuPG v1.4.11 (GNU/Linux)
hQIMA4rhrXgpby/VARAAmEt+KolkBRRzWW8ZDFrBGeHwDuLumAte2r2pnB+bb/wm
8ROFRKgeB86aHRQH+ynhYcnlWi1KwWANCqWZEPjcgxvuKGbofrGn4m4Bu5tkjvTt
NvOKV6jHdm7ri4g4RPRhPryJjHsWYxL7Exr15ZJiPCXhYU5+k2EZETVQcDbHUcRV
f2szsii+HaMTrS7P5zMyrFI5eCYxAm+ZX9Z9NYUraubaGoXBuiEIUvk7ydio//FG
xFBe7aCgOVSXigoHnsrF5QvdszNCcJAlPQC5t4g8tDLirj8JLsPvRX6uJJu/Y+xd
1v4/7KhsFKOrIGUhAvOsxb//HFo6CDO5T8OyeB+qCAf4bjMgTbkXKfRVvV1IKl0C
PX8CEoGHKzGsunIrtcqAsD+dofNnMmxWRrAg+bKfnFW4g3zKfuE6BF6FYueTqpaH
@Keruspe
Keruspe / stdin
Created February 25, 2015 17:35
stdin
https://gist.github.com/091f0fdd49035f87d712