Visual Studio – how to find source of heap corruption errors

Begin with installing windbg: http://www.microsoft.com/whdc/Devtools/Debugging/default.mspx Then turn on the pageheap like this: gflags.exe /p /enable yourexecutable.exe /full This will insert a non writable page after each heap allocation. After this launch the executable from inside windbg, any writes outside the heap will now be caught by this debugger. To turn of the pageheap afterwards use … Read more

Heroku server crashes with “JavaScript heap out of memory” when deploying ‘react-admin’ app

Contacted heroku support, here I solved the issue: The error has occurred because the node can only address 1.5GB of memory before hitting the JavaScript heap out of memory error, a default limit that it inherits from the V8 engine. We tweak this default setting on Heroku through the NODE_OPTIONS env var so that the … Read more

Good introductory text about GHC implementation?

The majority of the technical information about the architecture and approach of the GHC system is in their wiki. I’ll link to the key pieces, and some related papers that people may not know about. What typical optimizations are applied? The key paper on this is: A transformation-based optimiser for Haskell, SL Peyton Jones and … Read more

Creating “classes” in C, on the stack vs the heap?

There are several reasons for this. Using “opaque” pointers Lack of destructors Embedded systems (stack overflow problem) Containers Inertia “Laziness” Let’s discuss them briefly. For opaque pointers, it enables you to do something like: struct CClass_; typedef struct CClass_ CClass; // the rest as in your example So, the user doesn’t see the definition of … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)