fix compilation error

Using GCC 4.8.2, smcp isn't compiling out of the box due to undefined casts. This fixes the problem.