Fix the charset conversion logic in hooks.py

The proper way to convert text from byte oriented string to unicode
is to call str.decode(encoding). This patch fixes this and makes
Jenkins tests work for people with diacritics in their names.

The issue was caused by my name (with czech accents) being present
in an environment variable which was processed in hooks.py
using the following code:

scriptenv = os.environ.copy()
for k, v in scriptenv.iteritems():
    scriptenv[k] = unicode(v).encode('utf-8')

This unicode call expects the data to be in ascii, but my name was
encoded as utf-8 in this case.

Change-Id: I9063291f8a4a392b2913220fe2839386dcffd825
Signed-off-by: Martin Sivak <msivak@redhat.com>
Reviewed-on: http://gerrit.ovirt.org/15856
Reviewed-by: Dan Kenigsberg <danken@redhat.com>
Tested-by: Dan Kenigsberg <danken@redhat.com>