database-import: print nicer error-message on failure to load

did try to "load" a non-existing filename and got no clear error message.

still not nice... the read-file-and-pass-content-as-stream hack causes
using the empty string "" as source-id ... which will break all later
error-messages

maybe add "source_id" as fourth parameter to "Importer::load()" with
empty default value? would have to change all load() implementations...

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
typelib: replace non-existing type "InternalError" with "RuntimeError"

I assume "InternalError" was defined once upon a time. Its not anymore.
But oroGen knows an exception like this, maybe they are related? well,
crashing while crashing does not look very elegant. so limit the code to
just crash once.

see https://github.com/orocos-toolchain/orogen/blob/298c9dc70880af3afb6925f7d55c5fb414771b6e/lib/orogen/base.rb#L71

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
container-factory: throw "BadCategory" to prevent bad-casts

happens if someone wants to create a container with a name of a type
which is already in the database...

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
c++: try to return "NULL" for invalid pointers, instead of "0"

jeah, this is pedantic. but doing it like this is way clearer, to show
what is actually intended.

we should return "nullptr" after switching to c++11, but this would have
to wait.

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
registry.cc: use an explicit const_cast<>()

to make it clear what is happening here... a quite dangerous
const_cast-based hack...

Signed-off-by: Martin Zenzes <martin.zenzes@dfki.de>
Merge pull request #26 from jmachowinski/minor_fixes

Minor fixes