Skip to content

Instantly share code, notes, and snippets.

View BenLubar's full-sized avatar

Ben Lubar BenLubar

View GitHub Profile
@BenLubar
BenLubar / l4d2.json
Created May 10, 2013 04:07
L4D2 stats - first day
{
"Mechanic": {
"infected": {
"dual_pistols": 908,
"smg_silenced": 481,
"sniper_military": 666,
"smg": 209,
"pistol": 154,
"hunting_rifle": 296,
"autoshotgun": 257,
package main
import (
"bufio"
"bytes"
"encoding/binary"
"io"
"os"
)
@BenLubar
BenLubar / base.go
Created July 10, 2021 15:07
to be clear, none of these compile, and not just because of the syntax errors
package main
import "git.lubar.me/ben/spy-cards/card"
func main() {
var def card.Def
def.ID = card.Delilah
def.Effects = []*card.EffectDef{
{
@BenLubar
BenLubar / gonuts-markov: sanity=1.txt
Created May 29, 2013 23:58
5000 fictional chat messages from #go-nuts
08:41 < socratesxd_> ok
11:27 < Stavros> for some value in question
11:11 < ni291187> go files :).
12:45 < davecheney> each development as many people keep https://github.com/jnwhiteh/golang is always write a channel
13:54 < hgf> yeah, conky
19:59 < bigbob> hello. newbie here, though?
19:41 < foofoobar> cespare, i'll find a masochist
17:10 < zeebo> thats why would you do you did Google bought at least write two anonymous struct definition
04:53 -!- mkb218 -- so at those cases compared to read the segmented stacks?
06:50 < kc5tja> Courtesy of course, but java.
Conversation Flow ([ and ] represent 0 or more repetitions):
c->s handshake_request
s->c handshake_reply
[
c->s request
[
s->c text
]
s->c (result OR fail)
local dfplex = Proto("dfplex", "Dwarf Fortress Multiplexer")
local cmds = {
[0x6e] = "update",
[0x6f] = "sendKey",
[0x73] = "connect",
[0x75] = "resize",
[0x76] = "requestTurn"
}
local colors = {

I wish Ghidra could understand these constructs (or alternatively, I knew how to tell Ghidra to override these incorrectly decompiled statements)

Multi-field assignments

Simple example:

struct
{
 int16_t x;
int32_t add_to_vector(building *item,vector<building *> *vec)
{
int32_t size;
int32_t current_index;
int32_t current_index_00;
building **new_start;
building **new_start_00;
size_t old_size;
size_t old_size_00;
version: 1.0.{build}
pull_requests:
do_not_increment_build_number: true
branches:
only:
- master
skip_tags: true
image: Visual Studio 2017
configuration: Release
assembly_info: