Skip to content

Instantly share code, notes, and snippets.

View jrockway's full-sized avatar
🌒
Eclipse viewing

Jonathan Rockway jrockway

🌒
Eclipse viewing
View GitHub Profile
backend = "glx";
glx-no-stencil = true;
refresh-rate = 60;
vsync = "opengl-swc";
paint-on-overlay = true;
sw-opti = false;
unredir-if-possible = false;
@jrockway
jrockway / diffstat
Created May 11, 2014 10:09
openbsd 5.4 to 5.5 upgrade
root/etc/boot.conf | 2 +-
root/etc/ddclient/ddclient.conf | 191 +++++++++++++++++++++++++++++++++++
root/etc/dhclient.conf | 3 +-
root/etc/dhcpd.conf | 43 ++++----
root/etc/hostname.em0 | 4 +-
root/etc/hostname.gif0 | 3 +
root/etc/hostname.tun0 | 2 +
root/etc/hostname.vr0 | 1 +
root/etc/myname | 2 +-
root/etc/openvpn/blinky.jrock.us.crt | 92 +++++++++++++++++
@jrockway
jrockway / server.pl
Created April 3, 2009 11:22
stress test concurrent connections
#!/usr/bin/env perl
use strict;
use warnings;
use feature ':5.10';
use POE;
use HTTP::Engine;
my $body = "0"x1_000_000;
@jrockway
jrockway / evil.html
Created April 5, 2009 05:50
can a parent page remove "langauge features" from iframes?
<html>
<head>
<title>Test page</title>
</head>
<body>
<h1>Test page</h1>
Hello, world.
<script language="javascript">
document.write("Before: " + top);
top = null;
# Carp::Heavy uses some variables in common with Carp.
package Carp;
=head1 NAME
Carp::Heavy - heavy machinery, no user serviceable parts inside
=cut
# On one line so MakeMaker will see it.
@jrockway
jrockway / event.pl
Created June 9, 2009 13:40
event vs. non-event approach for writing to a child
#!/usr/bin/env perl
use strict;
use warnings;
use feature ':5.10';
use AnyEvent;
use AnyEvent::Handle;
open my $fd, '|-', 'perl -ne "sleep 1; print"' or die $!;
#!/usr/bin/env perl
use strict;
use warnings;
use feature ':5.10';
open my $fh, '>', 'test.txt' or die $!;
my $reopen = sub() {
open $_[0], $_[1]. '&='. fileno($_[2]) or die "failed to reopen: $!";
perl -MEncode=encode -e 'my $str = "\x{eeffff}"; my $enc = encode("utf-16be", $str); print join q{,}, length $str, do { use bytes; length $enc }'
my $hash = { keys => 'go here',
and => 'here',
};