Fix three compiler warnings.

The DecoderBase class was lacking a virtual destructor.
Two enum lists ended with a comma (which is allowed in C++11,
but is merely an extension in earlier versions of C++).
Setting an empty query clears the query.