libmtag-0.3.0: moved to git
I finally managed some time to make another libmtag release. This is mostly tiding up the code, cleanups, new codestyle, building improvements and moved to github
Also some handy features:
- strip tag: now you can remove say id3v1 tags while keeping id3v2 intact
- get specific tag: similarly, you can retrieve only id3v2 information
- get all: this function might is useful for some UIs, specify some callback, and get all the tags
I wonder why not so many people are using this, is there a better tagging library?
Any packagers interested?
Grab it while it’s hot
New adium build with msn-pecan 0.0.19
Thanks to Devid, we now have a build of Adium with msn-pecan, see the announcement at cocoaforge.
Enjoy
msn-pecan 0.0.19 released, more stability and “now playing” support
This is mostly a bugfix release that should make msn-pecan much more stable. Bug also brings some nice features such as “now playing” support.
Everyone is encouraged to update.
I’ve been busy with other projects so I have not been able to work as
much as I would have wanted, but all in all, this is a good release.
The features (thanks to Devid) include support for “now
playing” (ported from libpurple), and a new way to be notified when a
contact has deleted you (you’ll see on the conversation window). Also,
some issues in Adium were fixed, so we will probably roll an Adium
build with msn-pecan enabled.
I’ve updated my system so it might take a while before the win32
binaries are uploaded, anyone willing to take this one?
Download from the usual place at googe code.
Bugs fixed
- 99 Unable to retrieve display pictures when invisible or logged as invisible
- 109 Protocol priority
- 120 Aliases not cleared properly
- 133 pidgin crashed with SIGSEGV in msn_message_destroy()
- 154 Pidgin Randomly Crashes
- 135 russian translation doesn’t work
Enhancements
- 140 Support for “Now Playing” status field
- 129 Can’t verify installation, or uninstall
- 124 Notify when deleted by a contact
Taks
- 121 Make dbg package for the launchpad repo
Diffstat
105 files changed, 1295 insertions(+), 749 deletions(-)
Contributors to this release
Albert Cervin (1):
po: update Swedish translation
Devid Antonio Filoni (14):
Fix use_userdisplay option using Adium.
Change PACKAGE to GETTEXT_PACKAGE.
Translate msn-pecan also using Adium.
Fix use server alias option
Move utils/msgplustags.{c,h} to pecan_util.{c,h}.
Update COPYRIGHT.
Add PURPLE_STATUS_TUNE support and parse contacts's CurrentMedia.
Update MsnClientCaps in msn.h.
Add "Has Space" to get_info.
Show "You are not in A's contact list" message opening a conv
window if needed.
Set the passport also to session->user.
ab/pecan_contact.c: cleanup.
slp: destroy object at the right time
po: update Italian translation
Elias Julkunen (1):
po: update Finnish translation
Felipe Contreras (44):
Cleanup login steps.
Show up 'connecting' state.
session: Cleanups.
Trivial cleanups.
Cleanup configuration stuff.
session: Random cleanups.
Remove bad Russian translation.
cmdproc: trivial cleanup
slpcall: avoid extra error cb call
status: trivial cleanups
status: improve "available" state mapping
Trivial cleanups
userdisplay: report failure
Log general server notifications
Makefile: add debugging symbols by default
session: destroy ud manager after freeing slplinks
contact: store pecan status instead of pidgin one
Reorganize how bad statuses are handled
notification: store user state
contaclist: add function foreach_contact
Get user displays when returning from 'hidden' state
status: trivial cleanup
contact: use "invisible" for the HIDDEN status
Use pidgin mobile status only when offline
Update copyright notices
command: trivial cleanups
command: remove unused refcount
command: general cleanups
contact: enable workaround for server aliases
fix_purple: trivial cleanups
fix_purple: rename purple_buddy_set functions
Reorganize switchboard handling.
Close the http node when not needed.
Make sure the switchboard is not freed when it's still used by slplink.
transaction: trivial cleanup
transaction: add ref/unref
Properly ref/unref transactions
transaction: fix initial ref_count
sb: set error properly
Fix wrong memory access
Optimize GType retrieval
Fix SLP DATA message creation
po: general translation updates
Bump version to 0.0.19
Geoffrey Antos (1):
slplink: fix buffer overflow vulnerability
Luís Neto (1):
po: update Portuguese translation
Wei Hsiang Hung (1):
po: update Traditional Chinese translation
Response to Christian Schaller — Google, the LGPL and software patents
I read Christian Schaller’s post which says essentially that Google is evil because it’s using FFmpeg in Chromium and arguing the legality of it by using an unusual interpretation of LGPL. because Google is using an unusual interpretation of LGPL.
Let’s step back for a second and see this through the point of view of FFmpeg developers. Probably they, just like any other FOSS developer, just want to code kick-ass software, and the license (LGPL) is just a tool to make sure their software is not stolen, so if a company chooses to use FFmpeg, they must contribute the changes back.
Google is contributing back their changes, they are publicly available in their repo. So how could FFmpeg developers loose? Their code will be used in an amazing product, that they will probably use too, it’s a win-win situation. This subject was brought up on the mailing list and nobody complained; Chromium is not listed in FFmpeg’s hall of shame.
Now, is it legal? The only way to know is to bring the issue to court and see the resolution, but who will bring this to court? FFmpeg developers? No. Perhaps H.264 patent holders, but only in countries with wicked patent laws (USA), and who cares about them? If Google looses in court against H.264 patent holders, I wouldn’t consider it evil, quite the contrary.
And finally, Google lawyers said that what the FSF thinks about this movement is irrelevant… damn right! They wrote the license, so? FFmpeg choose the license, and FFmpeg can choose another license if they so wish, in fact, they can re-license to Google in any other license they see fit because they have the copyright. Of course there’s no need for that because LGPL works fine, and the explanation of Google lawyers is completely logical to me.
Personally I cheer the Google Chromium team for such a bold movement, and congratulate FFmpeg developers for making kick-ass software that might soon be even more widely used.
C programming hints and code-style (part 1)
Over the years I’ve had to deal with many different coding styles (can something without style be called style?). Here is a list of no-brainer tips that every C programmer should be aware of.
Hints
Update:
Have a copy of the C99 spec handy
Don’t scratch your head when you are not sure if a function is part of the standard, and what is the expected behavior, open the spec an check by yourself: here.
free() can receive NULL
There’s no need to do:
if (pointer)
free(pointer);
This works fine:
free(pointer);
Therefore if you write a struc_free function it makes sense to allow NULL as an argument.
There’s no need to cast a void *
tmp = (EXTEREMELY_UGLY_TYPE *) malloc(10);
malloc() returns a void * there’s no need to cast those:
tmp = malloc(10);
sizeof can receive a variable
size = sizeof(EXTEREMELY_UGLY_TYPE);
No need to burden yourself with that:
size = sizeof(tmp);
If tmp is a pointer you can do sizeof(*tmp) and so on.
Avoid big macros
Have you seen horrendous code like this?
#define ERROR(e, code, text) \
G_STMT_START { \
if ((text)) \
GST_WARNING_OBJECT ((e), "error: %s", (text)); \
gst_element_message (GST_ELEMENT((e)), GST_MESSAGE_ERROR, \
GST_STREAM_ERROR, (code)); \
} G_STMT_END
It’s much cleaner to use an inline function:
static inline void send_error(GstElement *e, int code, const char *text)
{
if (text)
GST_WARNING_OBJECT(e, "error: %s", text);
gst_element_message(e, GST_MESSAGE_ERROR, GST_STREAM_ERROR, code);
}
Yes, you can put inline functions in header files.
C99 is your friend
C99 has nice types such as bool (true and false), uint32_t and similar int types. Also these beauties:
static struct device = {
.base = 0x480bd400,
.irq = 24,
.pdata = {
.name = "isp",
.nr_tlb_entries = 8,
.clk_name = "cam_ick",
},
};
I don’t even want to imagine how horrible the code would look for C89.
Those are the ones I can think about, any suggestions? On the next part I’ll about code-style
How to explain FOSS to normal people, or: What does mountain bikes, rap music, and FOSS have in common?
Amazing talk: Charles Leadbeater: The rise of the amateur professional
These are my favorite quotes:
- How do we organize ourselves without organizations? … You don’t need an organization to be organized.
- One of the reasons [this view] is wrong, is that the ideas are flowing back up the pipeline. The ideas are coming back from the consumers, and they’re often ahead of the producers.
- Big corporations have an in-built tendency to reinforce past success. They’ve got so much sunk in it, that it’s very difficult for them to spot new markets. Emerging new markets then, are the breeding grounds for passionate users.
- What we are seeing is a complete corruption of the ideal of patents and copyrights; meant to be a way to incentivize innovation, meant to be a way orchestrate the dissemination of knowledge. They are increasingly being used by large companies to create thickets of patents to prevent innovation taking place.
- The reason why despite all the efforts to cut it down, to constrain it, to hold it back… why these open models will still start emerging with tremendous force, is that they multiply our productive resources, and one of the reasons they do that is that they turn users into producers, consumers into designers.
OMAP3 public DSP binaries now work
It took some time but finally tiopenmax 0.3.5 was released. It’s essentially 0.3 plus DSP binaries that actually work.
I verified with gst-openmax (git omap branch) and they work just fine
Thanks Daniel Díaz!
So people with OMAP3 hardware (beagleboard) can already try D1 MPEG-4 decoding using less than 15% of CPU. If you missed the demo, here it is:
All the information was available in my previous post. One minor update is that I’ve made a tag (v2.6.28-tidspbridge) to the linux-omap tree on my github repo to make it extra easy for people to compile a stable kernel with the dsp-bridge driver. There’s many DSP fixes available and some performance improvements which are not in this tag, but I’ll make sure they are once 2.6.29-omap1 is tagged.
100,000 views, and some stats
Well, it seems 100k views is a good milestone to talk about some stats of my blog, so here they are. I’m also trying to understand what are the sources of the traffic and how you might increase your viewers too.

Blog grow graph
General stats
- Total views: 102,436
- Busiest day: 1,903 — Monday, January 12, 2009
- Views today: 112
- Posts: 110
- Comments: 458
- Spam: 21,913 comments
As you can see I don’t post too often, but somehow I still manage to get some views. The day I got most views was the day the MSN servers did some strange update that made all new clients stop working. The new clients use MSNP13 and newer, while msn-pecan uses MSNP12. So everybody rushed to download the only Pidgin plug-in that worked. The number of downloads increased to 10,000 and many of those viewers ended up in my blog. Sadly, it lasted only one day.
But where does the normal traffic comes from?
Top 10 referring sites
- code.google.com/p/msn-pecan: 3,389
- maemo.org: 3,037
- maemo.org/news/planet-maemo: 974
- beagleboard.org: 694
- dzone.com/rsslinks/ruby_vs_python_on_web20_twitter.html: 677
- maemo.org/news: 578
- google.com/reader/view: 310
- fconfig.wordpress.com/2006/08/17/setting-up-a-fedora-nfs-server/: 276
- dzone.com/links/ruby_vs_python_on_web20_twitter.html: 245
- pplware.com/2008/03/29/pidgin-ainda-melhor/: 205
So, important planets like maemo.org and beablegoard.org constitute a big chunk of the visits. Maemo.org, specially, has a good voting system so good stories go to the top. Unfortunately I don’t blog so often about maemo-related stuff, and I try to not spam topic-centric planets.
Somehow that list seems not enough to fill 100k. Could be that Google is helping here?
Top 10 Google searches
- penn and teller bullshit episodes: 2,176
- tortillas: 1,375
- fedora 8 network install: 807
- gstreamer tutorial: 800
- fedora: 785
- fedora 7: 742
- bullshit episodes: 696
- pidgin msn: 594
- classic torrents: 590
- msn-pecan: 588
- public domain torrents: 527
- penn teller bullshit episodes: 527
Still some stuff seems to be missing. My guess? RSS feed subscribers. At least 66 people are subscribed to my blog through Google Reader. So, thanks to all the people that follow my blog. If you have any recommendation on how to improve it, please share it
Also, special thanks to WordPress for making this blog possible, and always providing great stats to help me figure out what to blog about next.
Finally, here is the list of top 20 posts:
Top 20
- Free TV episodes: Penn & Teller: Bullshit! (fun and enlightening): 10,681
- Fedora 8 network install from USB: 6,440
- Public Domain Torrents: Classic Movies and B-Movies For FREE!: 5,859
- Fedora 7 install from usb: 4,220
- Alternative MSN plugin for Pidgin: 4,011
- Get to know a little bit more about Mexican culture: 3,598
- Automounting a storage device with GNOME: 3,126
- Gaim/Pidgin rants, MSN history: 2,985
- Ruby vs Python on Web2.0: Twitter: 2,603
- NFS in Fedora 7 (and iptables): 2,363
- GStreamer hello world: 2,098
- Fedora 7 test 3 struggles: 2,031
- GStreamer hands-on introduction: 2,016
- gst-openmax demo on the beagleboard: 1,892
- Ruby on Rails on Fedora Core 6: 1,818
- msn-pecan 0.0.14 released: 1,669
- Transcoding for the Internet Tablets the smart way: 1,475
- Ogg Vorbis and Maemo 5; technical standpoint: 1,446
- msn-pecan 0.0.12 released: 1,399
- How to update to Fedora 7: 1,381
msn-pecan 0.0.18 released, now with voice clips support
Hello!
It’s time for msn-pecan 0.0.18. There are many bugfixes and important new features like voice clips support.
Again, Devid did most of the work. The most important fix is that personal status messages now work properly (can be enabled and disabled), the most important feature is voice clip support; thanks to Devid Filoni for the port, original patch from Chris Stafford, and Youness Alaoui for libsiren.
Also important is a fix for WLM 2009 user displays (Thomas Gibson-Robinson), P4-context support for groups.im (Thiago Silva and Devid), a new option to hide Plus! tags (Devid) and support for Plus! sounds (Devid and Thiago).
Also, some cleanups and reorganization heading towards a standalone library.
An interesting event happened on January 12; for some reason the MSN servers changed something that prevented many clients (>MSNP13) from working, while msn-pecan kept working just fine. That day the number of downloads increased dramatically (100010,000 a day), but unfortunately it lasted only a day.

12,552 page views.
New translations: Turkish, Portuguese (standard and Brazil) and Arabic. If your favorite language is not translated you can help at Launchpad’s site.
Here’s the diffstat:

Download from the usual place at googe code.