* EepGet: Add method to add extra headers to request

This commit is contained in:
zzz
2011-07-04 14:26:35 +00:00
parent 43044586d1
commit d4b28058a7
3 changed files with 34 additions and 3 deletions

View File

@@ -181,7 +181,13 @@ public class I2PSocketEepGet extends EepGet {
"Cache-control: no-cache\r\n" +
"Pragma: no-cache\r\n" +
"User-Agent: " + USER_AGENT + "\r\n" +
"Connection: close\r\n\r\n");
"Connection: close\r\n");
if (_extraHeaders != null) {
for (String hdr : _extraHeaders) {
buf.append(hdr).append("\r\n");
}
}
buf.append("\r\n");
return buf.toString();
}