Michal Čihař - Blog Archives for English

Playing with DLNA aka uPNP

Having Synology diskstation, notebook with XBMC and smart phone with Symbian, it should be possible to make all these talk together being able to play music stored on the diskstation using XBMC and controlled by phone, right?

I tried to set it up some time ago, but I used samba export on the diskstatio and all I found for controlling was XBMC Symbian S60 Remote v2, which is indeed useful, but choosing what to play remotely is quite limited. Luckily yesterday I've discovered world of DLNA aka uPNP and was surprised that this works pretty well. I've configured diskstation to behave as a uPHP media server, XBMC is able to act as media renderer and my Nokia E52 has ability to act as a controller. If you are lost in these terms, good overview is available here.

Well the control interface of Nokia E52 is far from perfect, but still provides good way to control all the stuff. Maybe I will look for some other solution in future, I'm sure it will exist as well.

phpMyAdmin translation status

We're heading to release candidates for phpMyAdmin 3.4.0, so the translators have less time to make the translations better. There are still 13 translations at 100%:

There are still lot of translations which would need some love, for example:

Recently, new people started to work on Bulgarian and Brazilian Portuguese translations, so we will hopefully have these two on the list soon as well.

You can help make translation to your language better! If your language is missing just let me know (either in comments or by email).

Photo of a week 11

I somewhat failed last week to take a photo because I was too busy with other things. However to stay on track I decided to publish about one month old photo from Charles bridge in Prague.

Gull on Vltava

GPL violation - getting more sources

It has been some time since I updated information about Gammu usage in proprietary software, so here it comes (see other posts tagged with gpl for more information).

I still have troubles to explain Anwsoft what they are supposed to release. The good news is that they are still communicating and even providing some updated sources (see git repository), unfortunately they still construct fake projects rather than providing real sources of the application.

Anyway if anybody is interested in digging in the sources and finding bits which might be interesting for porting to current Gammu code base, please go ahead, I probably won't have time for that in near future.

phpMyAdmin translation status

Last weekend we've released phpMyAdmin 3.4.0-beta4, hopefully last beta and there are still lot of translations missing. The only new complete translation compared to last week is German, so we now have 13 translations at 100%:

There are still lot of translations which would need some love, for example:

I'm happy that not only translation status is improving, but some translators also reviewed older translations, so that it is more consistent. The great work in this area was done in Russian. And of course there is still great ongoing effort on Urdu translation.

You can help make translation to your language better! If your language is missing just let me know (either in comments or by email).

Photo of a week 10

Tenth week and I'm still in. Honestly I did not expect to keep up that long. Last week there was a carneval at Žižkov (part of Prague) and the picture comes from it.

Žižkov carneval

Contributing to phpMyAdmin and GSoC 2011

It looks like questions about contributing to phpMyAdmin are more and more frequent with upcoming GSoC. The fact that is still time for organizations to apply and it's not yet decided whether we will be accepted or not does not change anything.

But before asking, please try to look up existing resources. We have lot of information available on wiki, with entry point being contribution page on website. You should find there all basic information how project works.

Should you specifically ask for GSoC, we have an applicant guide, which tells you what to do if you want to apply. After last year experiences, we will be even stricter on previous contributions, because it turned out to be good filter for people who would have problems with contributing during GSoC as well.

In case you don't know where to start, there is list of junior jobs which should not be that complicated and then there is of course GSoC ideas list with things primarily targeted on GSoC.

phpMyAdmin translation status

Another week is over and it's time to spam^W look again at state of translations for phpMyAdmin 3.4. There are no changes to list of complete translations, so we still have 12 translations at 100%:

There are still lot of translations which would need some love:

And I'm really happy to see progress of some exotic languages (at least for me) such as Urdu.

You can help make translation to your language better! If your language is missing just let me know (either in comments or by email).

Photo of a week 9

Next week is over and it's time to show another picture. Today I've decided for indoors photo, what is something I usually don't take, but here it is.

Pavlov wines

Fun with MinGW64 and ODBC

The test suite for recently added ODBC support in Gammu was consistently failing on Win64 platform (all others were just fine). It took me some time to figure out why. The reason is SQLLEN type, which is in some sort special, that generated code for it is broken.

All started with pretty much standard retrieving value from ODBC result:

SQLLEN size;
SQLRETURN ret;

/* Figure out string length */
ret = SQLGetData(res->odbc, 1, SQL_C_CHAR, NULL, 0, &size);
if (!SQL_SUCCEEDED(ret)) {
    return NULL;
}

/* Did not we get NULL? */
if (size == SQL_NULL_DATA) {
    return NULL;
}

/* Allocate buffer for string */
out = reallocate(out, size + 1);

The first problem was comparing of size against SQL_NULL_DATA. It simply always failed even if size did contain -1 (what is actually value of SQL_NULL_DATA). Yesterday, I've come out with typecasting magic that worked fine for this case.

However what I've missed is that even reallocate is failing with this parameter. No matter what the size would be, it would return NULL. Typecasting again did help here. Hey, should not be compiler clever enough to typecast this for me? It turns out that in case of MinGW64 it is not. Anybody has suggestion why?

At the end I ended up with pretty ugly duplicating of the variable just to avoid mixing it up in future changes (as would happen with typecasting everywhere).

I'd really like to know why my assumptions are wrong in this case.