Skip to main content

Blogs

No sound on FreeBSD 8.0

Posted in

I have successfully upgraded my FreeBSD 7.1 to 8.0, set up wifi (dues to wlan changes in 8.0) and everything worked just excellent. The only thing I missed to test was sound.

Qt Creator 1.3 on FreeBSD

Posted in

I think you remember, that earlier releases of Qt Creator didn't not work for FreeBSD out of box. All of them required some patching.

Run SQL query in vim

Posted in

Lets take a look at how commands can be executed in vim with passing some data from the file you are editing at this moment.

Qt 4.6-beta1 on FreeBSD

Posted in

A long-expected release of Qt 4.6 is coming out very soon. This is a great event because it brings in a lot of new features. As for me, the one I was looking for is the state machine framework.

Trivial do-while loop

Posted in

You might have seen such code.

do {
// ...
} while (0);

Me personally have seen it a lot and never knew what was this for.

There 2 reasons for doing this:

Scratchbox2 on FreeBSD

Posted in

I wondered how much efforts would it take to run Scratchbox2 on FreeBSD. I hoped that everything will be fine, but I have immediately got the first error at configure run:

 

Passwordless SSH

Posted in

Assume that you need a passwordless access to TARGET computer via SSH from ORIGIN computer. You need an authorization key for that:

user@ORIGIN> ssh-keygen -t rsa

Problem #3

Posted in

int var = 7;
printf("%f\n", var);

Q: What will this print?
A: Unpredictable behavior

Problem #2

Posted in

static int a = 0, b = 3;
 
int change_a() { return ++a; }
int change_b(int x) { return b+=x; }
 
void func(int x)
{
    static int aa = change_a();
    static int bb = change_b(x);
}

Problem #1

Posted in

struct S {
    static int i;
 
    S() { ++i; }
    S(const S&) { ++i; }
};
 
int S::i = 0;
 
int main() {
    S v(S());
 
    return S::i;
}

Syndicate content