Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Getting 'unexpected response' in ReportManager.m #113
Downloading reports started failing today in downloadReport. For some reason, my headers don't contain either 'Filename' or 'filename', so it fails with 'unexpected response'. Here is a dump of the headers, if it helps:
(gdb) po [downloadResponse allHeaderFields]
OK, found the source of the bug. In fetchReportsWithUserInfo:, the lines:
are bad, because my dailyName is 'theForm:j_id_jsp_60478444_6'. These lines will replace BOTH occurrences of '_6' when the intention is to only replace the final occurrence. We should probably restrict the string replace with a range of just the final two characters of the string.