fix #11 multiple connection and added test
add checking of charset.