Skip to content

Instantly share code, notes, and snippets.

View Mattosx's full-sized avatar

mattos Mattosx

  • Netease
  • Hangzhou
View GitHub Profile
@francoism90
francoism90 / README.md
Last active May 4, 2024 12:52
Change country to unlock channels, increase TX-power. (Use at your own risk)

Warning

Following instructions are provided without any warranty, and may even get you in trouble legally. The instructions are provided for testing, and should be use with care. We (including commentators) are not responsible for any damage to your device(s).

Introduction

This may enable additional channels and power (in most cases don't) on ASUS Merlin provided routers.

@thynson
thynson / C++17-Value-Category-System.md
Last active January 22, 2022 16:12
C++ 17 Value Category System

C++ 17 Value Category System

-----------------------------
|   glvalue       |         |
-----------------------------
| lvalue | xvalue | prvalue |
-----------------------------
|        |     rvalue       |
-----------------------------
@mastermatt
mastermatt / round_compat.py
Last active December 5, 2019 09:09
Python round compat (bankers round for python2).
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import decimal
import fractions
import math
import six
@yamnikov-oleg
yamnikov-oleg / LICENSE
Last active April 29, 2024 19:30
Shared (interprocess) mutexes on Linux
MIT License
Copyright (c) 2018 Oleg Yamnikov
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
@wong2
wong2 / cmds.txt
Last active May 2, 2021 12:13
在任意聊天中输入。 [ ]表示后面要跟一个空格(可能还需要别的参数才能生效)
//wearversion
//wearlog
//wearvoiceinputenable
//wearvoiceinputdisable
//weargoogleapi
//assert
//pushassert
//uplog
//upcrash
//switchnotificationstatus
@christianparpart
christianparpart / monkeypatchor.cpp
Created May 24, 2012 18:06
Monkey-Patching in C/C++ :-)
// compile me: g++ -shared -fPIC -ldl -o monkeypatchor.so monkeypatchor.cpp
// use me: LD_PRELOAD=`pwd`/monkeypatchor.so /bin/ls
#include <dlfcn.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/mman.h>
void* (*malloc_super)(size_t);
void (*free_super)(void*);