For me these line can be the source of the problem :
Qt Code:
  1. pr += line.split('=')[1] + "\r\n";
To copy to clipboard, switch view to plain text mode 
You assume that the line always contains at least one = sign. And what if he is not there ?