portable UI tip #1

if there is a blinking caret in the field then show a keyboard. There is nothing more annoying than having to ‘repick’ the text field that is currently active, with the blinking caret

what are you thinking android? focus is something explicit, not implicit. You do not have to have an active control on a form at all times. that and the fact that the keyboard is very tough to get rid of when you want to.

Ubuntu netbook edition… Not for amateurs

So this afternoon I was at a friend’s house trying to get his ubuntu netbook working with a broadband dongle. It just refused to connect, and on failure displayed a notification dialog that basically read ‘did not work’. Once this dialog appears, the only way to reattempt a connection is to unplug and replug the broadband dongle, as ‘networkmanager’ disables the connection when it fails.
There were logs – the fine syslog.log file, which is almost completely useless for diagnosing the failure in the connection – it seems to be telling me that the connection succeeded, but then was immediately disconnected. About as useful as a slap in the face with a wet haddock.
armed with my iPhone I first attempted to ensure that the connection details were correct. The management tool added the settings, so I immediately did not trust them. Google pointed out some options, but every time the connection failed there was another 30+ second delay unplugging, replugging and reentering the PIN (it ignored the pin option in the network manager configuration).
I fired up my laptop running Windows. It installed the management tool, I looked at the settings, shouted at both the Internet and the ubuntu configuration, both of which were telling complete lies about the settings. Here’s a hint for all you mobile broadband providers – make the settings easily findable using google – there is a lot of outdated and completely invalid information out there that makes this an issue.
so, ultimately, a problem that I struggled with for quite a while under ubuntu was solved in less that 30 seconds under windows, and yet another reason why I think that NetworkManager is a thing of satanic horror that makes using computers under Linux a complete pain in the arse. This ‘solution’ is probably the singularly worst example of dumbing down configuration to the point when something goes wrong, it is practically impossible to diagnose or fix the problem.
In this case, I will have to say… progressive disclosure is a good potential solution to complicated user interfaces. The complete excision of all forms of configuration into the magical tool of automagic only works if it works all the time, and as a friend is fond of saying “If you design a system that it cannot fail then the first thing that happens is that it will.”

Is that a DLL in your pocket…

Shock! Horror! Bug found where Windows applications will open DLLs that are in the current working directory of a process!

Except it’s not a bug. It’s by design, and it’s existed since NT.

Microsoft is being smacked in the head by a required feature of Windows due to the initial weakness of the LoadLibrary call. If you don’t specify a path to the file to load, it uses the standard library search path.

Dear god, you would think that this was news. It is not news, nor has it been since the goddamned operating system shipped. Granted, the issue is severe, but the fact of the matter is if an application is executed using a working directory that isn’t under your control, then what can you do? if there are libraries in the same directory that launched the program that happen to share the name of system libraries then you’re hosed.

Hey, guess what asshole, if you link a linux binary with a search path containing ‘.’, then you get the same problem. It’s just as well that nobody links their binaries with -R. …. eh?

The documentation is blatant in this regard. I’ve known it was a security issue since I first learned of the LoadLibrary call, as any even half decent developer should have known when they started using the damned function.

The rule is simple. Resolve the full path to a library before you load it. Validate that it ‘looks right’ at that point. Then load it.

BTW .init section in .so files – so totally a security hole. You can’t dlopen a file to determine if it’s good without executing the .init code. Game over man, game f**king over!

My .init code does a setenv(“LD_LIBRARY_PATH”, “.” + getenv(“LD_LIBRARY_PATH”)) … now piss off and write secure code for once…

Very heavy requirements

I have been buying sound cards for a loooooong time – my first add-on card was for a 512K Amsdrad PC512 and it produced either MIDI-based sound or replicated sample audio. It was not a cheap purchase at the time – I can’t remember the price any more, but it was quite a bit of savings at the time.

It came with a literal ‘wodge’ of 5.25" driver diskettes. you could use it to steady a table there were so many of them.

Later on, the disks changed to 3.5". This meant that they were thicker than the older disks, and amounted to a pile that simply got progressively larger. By the purchase of my last soundblaster card, I was looking at IIRC 10 disks, only a few of which were usable for drivers for DOS, the remainder were ‘assistant’ programs such as Dr. Sbaitso, which were to purposes useless.

I spent a long time kind-of caring about my sound card. I bought an SB live card for my main desktop and for several years things just worked. About 2 years ago got an SoundBlaster X-Fi card for notebooks for my Dell Insipron M1710. Honestly, the internal card was better than the add-on card. I didn’t really care as I paid for it in Yen, so it didn’t count towards cost.

In the last 6 months I bought a new rig. Reasonable price, and harkening back to my memories, I got an SB X-Fi XtremeGamer card. Not a large outlay (<€80). It no longer comes with a wodge of disks – it downloads software and updates from the internet.

The smallest update for this software seems to be 50MB. The sum total of the latest software update (to fix problems and to increase compatibility on Vista) is 235MB. I am 44MB into the update and I’m being told that there’s another 2.5 hours to go. I’m not on a slow link either. It just seems to be on their side.

Just to put this into perspective – The download for my soundcard is about 1/2 the size of a reasonable Linux distro… and it’s as slow as a wet weekend in June. By the time this update has downloaded I could have watched the entirety of the latest Harry Potter movie and still had time for a pint. It’s damned slow.

This is a sound card. Not the World Management Software Suite®. The update for my graphics card was 90MB and that was Driver + Support Software + PhysX Drivers. And it downloaded in less than 10 minutes.

Now that I recall, all the problems I seemed to have on the older machine could always be traced to limitations or issues with my sound card. A driver that wasn’t playing by the rules. Maybe it thought it was being edgy? I’ve seen too many BSODs to want edgy. I just want something that works…. and doesn’t need a 250MB update (that’s twice the size of OpenOffice)…

Oh, and Windows Live Writer — please convert euro, trademark and em-dash symbols before posting… we’re not all using UCS-16 encoding here. Some of us actually try to use the web in a platform independent manner…

Can you people please collate FFS

Nothing more than a rant….
It’s not that tough – when using most english locales, we sort case insensitively. a==A, B==B and so on. Pragmatically, the only reason for picking a locale other than UTF-8.generic is because I would really, really like these rules obeyed.
I am sick to death of having to work around stupidity.
I’m just complaining as I look at the output from ls and it’s pretty much a case sensitive sort. I’m sure that accents are sorted correctly in EN_ie – after all á is the same as a, but apparently it’s different to A.
Sorting it difficult… the rules are so complicated… stop complaining! you’re able to perform at least 600 million operations per second, and a table lookup for a case insensitive sort is probably going to cost 20.
Bear in mind that the number above was a quick back of the envelope number of an iPhone. I’m sure a real computer will be able to do something a little better…


Looks like it’s not Linux, it’s only Leopard that doesn’t understand EN_ie collation. Oh well, that’s life I suppose…

Internet bandwidth usage

This is one of those odd things. For several years I have paid a data plan on my mobile phone to read my email. I think at the first time I paid it, they were looking for about €10 for 10MB of data (up and down). As time has passed I have still been paying this internet tax for the phone, only in the last two years with the purchase of a Nokia N95 has it become something of a complete fraud.
I’ve just lost this entry due to it being (a) a web 2.0 item and (b) not capable of dealing with the downing of my internet connection. Not making me a happy camper.
I bought the phone, while I still had my €13 for 10MB data connection plan. There was nothing better available. I assumed (more fool me) that there would be an option for a better data plan as I was buying a phone which required a half decent packet connection. Apparently, my mobile company were unaware of the fact that my phone was using the packet connection until I was in excess of €300 in the hole, and that was a paltry 2 weeks after getting the phone. Something to do with them being complete pillocks.
After a while, a plan became available that allowed for 1GB data per month. I barely use 100MB on the phone (I have a broadband dongle and am paying for broadband access in two locations simulataneously). I will be using my phone to tether my laptop. This is a given.
Apparently, the new phone plans for the iPhone and tethering will ask for a supplemental €15 which is epletivingly ridiculous. You cowboys have been charging us 10cent per 160 7bit message which is 64cent a KB or €655 a MB. All the code to deal with these is built into the system. The messages themselves pass through a mostly unused D-channel. They are free. Stop taking the piss. Data access should be a right – just like food and shelter.

Aargh! And it’s less than a week old

I bought an internet radio for the mother for Christmas – it means that she can listen to BBC Radio 4 without it sounding like complete rubbish over long wave. It worked fine for a few hours in the morning on Christmas day then it malfunctioned – the volume started to act as though the volume up button was jammed down. I can’t reset it – the behaviour makes it completely unworkable. It seems to be some form of short circuit. After I powered it off overnight, it seemed to work again – for about 10 minutes, then I got the same behaviour. With sadness I shall be returning it to the store to get a replacement unit, which, I hope, will work much better.

The issue it that it’s frustrating, I don’t think that it’s a problem endemic with the model as there seem to be a lot of people with the same model, none of whom seem to be complaining about it.

Generic rant against ‘security’

Ok, this is me too, but at least I listen to myself… most of the time.
firstly, listen to the user. If they repeat something more than once then it probably means that they want to ignore that particular thing all the time. Let’s be honest, when my mail host sends me the same certificate for the umpteenth time, you’re likely to guess the answer based on the last 200000000 times I clicked Yes.
Oh, no you disclaim! this is security! people need to be saved from their stupidity.
The problem is that the current ‘security’ and ‘authenticity’ system is supported by money.
I can pay someone enough money and they will probably claim that I’m the first bank of owning all your children – and because of the trust system, you won’t be able to disavow that claim. After all I paid my $200 to get that claim.
The entire system of trust on the internet is based on a first-come-first-served monopoly of ‘I trust you’ mechanisms. This is simple, but ultimately a poor trust mechanism.
The solution probably involves a complex series of gpg keys, but ultimately it would be more satisfactory because:

  • It does not involve money
  • trust can be reduced as well as increased

This rant was brought to you by shredder aka thunderbird 3 – after all you are too stupid to manage your own email; even though you just want a secure channel between you and the email server.