[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] /srv/bzr/gnash/rtmp r9956: look for the ? that seperates
From: |
rob |
Subject: |
[Gnash-commit] /srv/bzr/gnash/rtmp r9956: look for the ? that seperates the parameters from the filespec. |
Date: |
Sun, 18 Jan 2009 17:59:53 +1100 |
User-agent: |
Bazaar (1.5) |
------------------------------------------------------------
revno: 9956
committer: address@hidden
branch nick: rtmp
timestamp: Sun 2009-01-18 17:59:53 +1100
message:
look for the ? that seperates the parameters from the filespec.
modified:
libnet/http.cpp
=== modified file 'libnet/http.cpp'
--- a/libnet/http.cpp 2008-12-29 16:05:34 +0000
+++ b/libnet/http.cpp 2009-01-18 06:59:53 +0000
@@ -183,7 +183,7 @@
return _cmd;
} else {
return HTTP::HTTP_NONE;
- }
+ }
}
// A GET request asks the server to send a file to the client
@@ -1302,7 +1302,7 @@
HTTP::http_method_e
HTTP::extractCommand(boost::uint8_t *data)
{
-// GNASH_REPORT_FUNCTION;
+ GNASH_REPORT_FUNCTION;
// string body = reinterpret_cast<const char *>(data);
HTTP::http_method_e cmd = HTTP::HTTP_NONE;
@@ -1335,9 +1335,16 @@
if (cmd != HTTP::HTTP_NONE) {
boost::uint8_t *start = std::find(data, data+7, ' ') + 1;
boost::uint8_t *end = std::find(start + 2, data+PATH_MAX, ' ');
-
- // This is fine as long as end is within the buffer.
- _filespec = std::string(start, end);
+ boost::uint8_t *params = std::find(start, end, '?');
+// cerr << "FIXME1: " << (const char *)params << endl;
+// cerr << "FIXME2: " << (const char *)start << endl;
+// cerr << "FIXME3: " << (const char *)end << endl;
+ if (params != end+1) {
+ _params = std::string(params, end);
+ end = params;
+ }
+ // This is fine as long as end is within the buffer.
+ _filespec = std::string(start, end);
}
return cmd;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] /srv/bzr/gnash/rtmp r9956: look for the ? that seperates the parameters from the filespec.,
rob <=