This file contains 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
#!/usr/bin/env python | |
import subprocess | |
import re | |
class Membase: | |
def __init__(self, agentConfig, checksLogger, rawConfig): | |
self.agentConfig = agentConfig | |
self.checksLogger = checksLogger | |
self.rawConfig = rawConfig |
This file contains 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
<?php | |
class Application_Model_DbTable_Video extends Zend_Db_Table_Abstract | |
{ | |
protected $_name = 'VIDEO'; | |
protected $_sequence = 'VIDEO_SEQ'; | |
protected function | |
editableFieldsOf(array $data) { |
This file contains 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> | |
#include <string.h> | |
#include <stdlib.h> | |
#include <stdbool.h> | |
%%{ | |
machine redis_parser; | |
action reset_line { |
This file contains 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
<?php | |
class NewRelic_Error extends Exception {} | |
function NewRelic_Date(DateTime $date) { | |
return $date->format('Y-m-d') . 'T' . $date->format('H:i:s') . 'Z'; | |
} | |
function NewRelic_Metrics2Array(SimpleXMLElement $result) { | |
$return = array(); |
This file contains 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
<?php | |
if( FALSE == isset($_SERVER['REDIRECT_URL']) ) { | |
if( FALSE == isset($_SERVER['PATH_INFO']) ) { | |
$_SERVER['REDIRECT_URL'] = $_SERVER['SCRIPT_NAME']; | |
} | |
else { | |
$_SERVER['REDIRECT_URL'] = $_SERVER['PATH_INFO']; | |
} | |
} |
This file contains 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
/** | |
* License: WTFPL - http://sam.zoy.org/wtfpl/ | |
* Copyright: (c) 2012 Derp Ltd. <openrating@derp.ltd.uk> | |
* Version: 0.1 | |
* Authors: Harry Roberts | |
*/ | |
module openrating; | |
import std.stdio; | |
import std.datetime; |
This file contains 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
#lang racket | |
(require ffi/unsafe | |
ffi/unsafe/define) | |
(define-ffi-definer define-libevent (ffi-lib "libevent")) | |
; Event Base | |
(define evbase-ptr (_cpointer 'evbase)) | |
(define-libevent event_base_new (_fun -> evbase-ptr)) | |
(define-libevent event_base_dispatch (_fun evbase-ptr -> _void)) |
This file contains 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
<?php | |
class DB extends PDO { | |
function __construct($dsn, $user = NULL, $password = NULL) { | |
$params = array( | |
PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES \'UTF8\'', | |
PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => TRUE, | |
PDO::ATTR_PERSISTENT => TRUE, | |
PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION, | |
PDO::ATTR_ORACLE_NULLS => PDO::NULL_EMPTY_STRING, | |
PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC); |
This file contains 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 "SDL.h" | |
#include "SDL_gfxPrimitives.h" | |
#include "SDL_framerate.h" | |
#include <stdbool.h> | |
#include <math.h> | |
static const int laycnt = 7; | |
static int layalpha[7]; | |
static double lay[7]; |
This file contains 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 "SDL.h" | |
#include "SDL_gfxPrimitives.h" | |
#include "SDL_framerate.h" | |
#include <stdbool.h> | |
#include <math.h> | |
#include <stdio.h> | |
double derp = 0; |