fix issue  #346