This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'https://rubygems.org' | |
# ... | |
# zbar needs an environment variable, so don't require it automatically | |
gem 'zbar', require: false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/zbar/jpeg.c | |
+++ b/zbar/jpeg.c | |
@@ -79,8 +79,15 @@ | |
void skip_input_data (j_decompress_ptr cinfo, | |
long num_bytes) | |
{ | |
- cinfo->src->next_input_byte = NULL; | |
- cinfo->src->bytes_in_buffer = 0; | |
+ if(num_bytes > 0) { | |
+ if (num_bytes < cinfo->src->bytes_in_buffer) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# I split up jux.desktop-c2366d6aa995c5fe80506debabee8ee2.css into parts: | |
# - one file for .theme-day | |
# - one file for .theme-dusk | |
# - one file for everything else | |
# | |
# My thought was that Jux.com could load the relevant theme CSS, and unload | |
# the unused theme(s). This would result in significantly fewer active CSS | |
# rules and some savings of data transfer without requiring much in terms of | |
# code changes. | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
line_classifier: line_classifier.o | |
%.c: %.rl | |
ragel -G2 $^ -o $@ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- PostgreSQL current | |
SELECT | |
round, | |
first_value(time) OVER pair AS first_time, | |
last_value(time) OVER pair AS last_time, | |
first_value(groundstatsid IS NULL) OVER pair AS first_is_standing, | |
last_value(groundstatsid IS NULL) OVER pair AS last_is_standing | |
FROM matchstats | |
WINDOW pair AS (PARTITION BY round ORDER BY time ROWS 1 PRECEDING); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ curl -O -v https://s3.amazonaws.com/willglynn/physfs-2.1.0-pre20121013.tgz | |
* About to connect() to s3.amazonaws.com port 443 (#0) | |
* Trying 207.171.163.13... | |
% Total % Received % Xferd Average Speed Time Time Time Current | |
Dload Upload Total Spent Left Speed | |
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* connected | |
* Connected to s3.amazonaws.com (207.171.163.13) port 443 (#0) | |
* SSLv3, TLS handshake, Client hello (1): | |
} [data not shown] | |
* SSLv3, TLS handshake, Server hello (2): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Race Into Space uses different palettes in different screens. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ make packing | |
cc packing.c -o packing | |
$ nm packing | sort | |
U dyld_stub_binder | |
0000000100000000 T __mh_execute_header | |
0000000100000f50 T _main | |
0000000100001000 S _bar | |
0000000100001010 S _foo | |
0000000100001074 S _packed_bar | |
0000000100001080 S _packed_foo |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class SomeClass; end | |
module SomeClass::NestedModule; end | |
puts SomeClass.class | |
puts SomeClass::NestedModule.class | |
# prints: | |
# Class | |
# Module |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main() { | |
struct { | |
int scalar; | |
int array[5]; | |
} some_struct; | |
some_struct.scalar = 5; |