CD woe

I found a bug in libcdaudio today.

I noticed some CD info was corrupt for compilation CDs.

The last letter of the track and the first letter of the artist was being chopped off.

An example can be seen here.

I finally traced it to something in libcdaudio that was parsing the track artists and titles incorrectly.

Luckily it proved easy to fix.

I’ll run my modified version for a few days and if it’s fine I’ll mail the maintainer.

The real problem I have is how to update all my incorrectly parsed CDs without physically reloading them all.

I may have to write a little C program that calls libcdaudio for each CD in my cache.

I don’t particularly enjoy writing C. 🙁

Caching is fun!

I have been writing some caching code for the site.

At present, every hit on the CD list results in a hit on the db.

I wrote a generic caching class to keep a cache of db results to look in instead.

I was quite amazed that it all worked the first time I ran it, especially as there were thread synchronisation issues involved.

I will test a bit more before sending live though.

Next step, pagination, one page with 80-odd CDs on it is not the most usable is it. 🙂

Thief stopped

Having mulled over various options, I came to the conclusion that asking the poster to give me credit was pointless.

Nobody had viewed that post in 8 days or so, and I knew nobody was likely to now.

I chatted to a friend and he talked about blocking access with Apache.

We looked at the Apache site and eventually found this (you have to scroll to the bottom of the page).

It’s called Prevent Image Theft and it basically allows you to prevent people accessing a file if the referrer wasn’t from your site.

Appplying this config change to my images completely blocked my photo from appearing on his post while not affecting my site at all.

It’s not a perfect solution but it works in this situation.

Stop thief!

I decided to look at web stats for my photo sites today.

I found I was getting an awful lot of referrals from a particular site so I looked into it.

It turns out that someone on a bulletin board has linked to one of my photos from their post. Everyone who views the post is pulling data from my site, but no credit is given to me.

This to me is in violation of the usage terms for the photos on my site.

Although I suppose it could be argued by some that it’s not in violation as the image is still on my site.

Anyway, what do I do?

  • Remove/rename the image?

  • Replace the image with something else (something funny, or even insulting/offensive)

  • Contact the poster and ask him/her to give me credit

  • Report it as a violation using the "report abuse" link on their site

  • Put my site URL on all the photos as text

  • Do nothing

I’ll have a think about it and will post more when I decide.

Site update

I made a few updates to the site.

  • I added a blog.

  • The CD list now has a count of how many times I played a particular CD.

    The last one played is on the front page too.

  • The site navigation is a bit neater with sub-menus within certain sections.

  • Also, I made some structural code changes which make adding new stuff to the site far easier.

    More info on that later for the more technically inclined.

Let the blogging commence

I have added a blog to the site.

Also known as a weblog, if you’re not into that whole brevity thing.

Anyway, this will be the place where I waffle on endlessly about random crap.

Stuff I expect to waffle about may include:

  • Programming & other techie stuff
  • Football
  • Something really interesting that happened to me the other day
  • Work
  • Things & Stuff


Zion National Park, Utah, click to see more photos of Zion Photos

Finished off the photos for my trip to USA last year, and did a mini-site for a trip to Scotland I took.

I also gave all three photo sites a face lift.