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
| ///////////////////////////////////////////////////////////////////////////// | |
| // Dispatch map | |
| BEGIN_DISPATCH_MAP(CCircCtrl, COleControl) | |
| //{{AFX_DISPATCH_MAP(CCircCtrl) | |
| DISP_PROPERTY_NOTIFY(CCircCtrl, "CircleShape", m_circleShape, OnCircleShapeChanged, VT_BOOL) | |
| DISP_PROPERTY_NOTIFY(CCircCtrl, "FlashColor", m_flashColor, OnFlashColorChanged, VT_COLOR) | |
| DISP_PROPERTY_EX(CCircCtrl, "CircleOffset", GetCircleOffset, SetCircleOffset, VT_I2) | |
| DISP_PROPERTY_EX(CCircCtrl, "Note", GetNote, SetNote, VT_BSTR) | |
| DISP_STOCKPROP_BACKCOLOR() |
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
| if (a[o + 22 | 0] << 24 >> 24 == 24) { | |
| if (!(Vp(d, o | 0) | 0)) { | |
| break | |
| } | |
| p = (c[m >> 2] | 0) + (((c[h >> 2] | 0) - 1 | 0) * 40 & -1) + 12 | 0; | |
| q = o + 28 | 0; | |
| c[p >> 2] = c[q >> 2] | 0; | |
| c[p + 4 >> 2] = c[q + 4 >> 2] | 0; | |
| c[p + 8 >> 2] = c[q + 8 >> 2] | 0; | |
| c[p + 12 >> 2] = c[q + 12 >> 2] | 0; |
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
| @import <foundation> | |
| @implementation Person : CPObject | |
| { | |
| CPString name; | |
| } | |
| + (id)personWithName:(CPString)aName | |
| { | |
| return [[self alloc] initWithName:aName]; | |
| } | |
| - (id)initWithName:(CPString)aName |
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
| import java.applet.Applet; | |
| import java.awt.*; | |
| // Applet code for the "Hello, world!" example. | |
| // This should be saved in a file named as "HelloWorld.java". | |
| public class HelloWorld extends Applet { | |
| // This method is mandatory, but can be empty (i.e., have no actual code). | |
| public void init() { | |
| } | |
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
| setInterval(function(){ | |
| if(window.devicePixelRatio > 1) { | |
| jQuery('img.profilePic').each(function(){ | |
| var el=this; | |
| if(!el.src.contains('gravatar.com')) return; | |
| el.src = el.src.replace(/\bs=(\d+)/, | |
| function(match, px) { | |
| return "s="+Math.round(window.devicePixelRatio*jQuery(el).innerWidth()); | |
| }); | |
| }); |
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
| // [true, true, true]: | |
| [ | |
| 0 === -0, | |
| Math.atan2(0, -0) === Math.PI, | |
| Math.atan2(0, 0) === 0 | |
| ] | |
| // [false, false]: | |
| [ | |
| -0 < 0, |
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
| - return HttpResponse(simplejson.dumps(data), mimetype="application/json") | |
| + | |
| + # The Django Session middleware helpfully adds 'Cookie' to the Vary header if request.session.accessed is true | |
| + # Firefox won't cache JSON if the response varies by cookie. | |
| + # Since we mark Cache-Control: private and max-age:60, the attack vector here is very very small: | |
| + # People on the same machine as the victim, who read the cache within 60 seconds | |
| + # So, let's fake out the session middleware to not send the Vary: Cookie header, just Vary: Accept-Encoding. | |
| + request.session.accessed = False | |
| + | |
| + response = HttpResponse(simplejson.dumps(data), mimetype="application/json; charset=utf-8") |
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
| var throwup = require('throw').throwup, makecallable = require('throw').makecallable; | |
| var even = throwup(_even), | |
| odd = throwup(_odd); | |
| var r = makecallable(_even)(parseInt(process.argv[2], 10) || 5000, 0); | |
| console.log('found2', r); | |
| function _even(n,j) { | |
| if(n>0) return odd(n-1, j+1); |
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
| var throwup = require('throw').throwup, makecallable = require('throw').makecallable; | |
| var recurse = throwup(_recurse); | |
| var callable_recurse = makecallable(_recurse); | |
| var result = callable_recurse(parseInt(process.argv[2], 10) || 5000, 0); | |
| console.log('found', result); | |
| function _recurse(n, j) { | |
| if(n>0) return recurse(n-1, j+1); | |
| else return j; |
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
| function throwup(fxn) { | |
| return function() { | |
| throw [fxn, Array.prototype.slice.call(arguments)]; | |
| } | |
| } | |
| function makecallable(fxn) { | |
| return function() { | |
| var params = Array.prototype.slice.call(arguments); | |
| while(params) { |