Archive for July 21st, 2008

сніжок.net

Just a test сніжок.net :mrgreen:

PS: If the URL looks horrible, it’s Firefox or IE. No further comment ;)

CSimpleBuf, a C++ utility class under BSD license

Today I am happy to announce the release of a C++ buffer class that is of special use for interfacing with Windows system functions. The class is a template class and thus only one header file is needed. The template argument is the “character type”. However, please note that the “character type” can be literally anything, including unsigned int or even an arbitrary struct.

Friðrik, my boss at FRISK Software International (FRISK), was so generous to allow the release of this C++ utility class under a non-copyleft license. He agreed on the new (simplified) BSD license. This allows everyone to use this code for free, with the only “restriction” being that attribution has to be given. Even Microsoft is using code under BSD license (TCP/IP stack and utilities).

So, what does the class offer? Well, first of all the standard operations you’d expect from a simple string class such as concatenation and assignment (those are based on the idea of C-strings being zero-terminated) . But what sets this class apart from other simple buffer classes that I have found, as well as from the string classes which tend to be very restrictive when it comes to modifying the buffer they encapsulate is the fact that it can be used seamlessly with most APIs. The only exception from the rule are APIs which expect an untyped pointer (including ellipsis arguments), in which case you have to use the Buffer() member function. It offers resizing of the buffer (ReAlloc(x);) as well as completely freeing it (ReAlloc(0);) or zeroing it out with Clear();.
Continue reading ‘CSimpleBuf, a C++ utility class under BSD license’

Windows in XEN domU on laptop, using screen and VGA?

Does anyone among my readers have a clue whether or not it is possible to set up XEN in a way so it will pass control over the screen to a domU to which I want to assign it? It would be a nice scenario for having both Linux and Windows running in parallel on the same box while still being able to use all those 3D-features of the graphics card. But from what I found so far, it doesn’t really seem to be possible.

Apart from firewall/proxy scenarios it would offer some other creative ways of using the laptop.

// Oliver