Bug Tracker – Bug 419

Parse odamex:// protocol URIs

Last modified: 2014-03-20 00:23:58 UTC
Bug 419 - Parse odamex:// protocol URIs
Summary: Parse odamex:// protocol URIs
Alias: None
Product: Odamex
Classification: Unclassified
Component: Server & Client (show other bugs)
Version: (old) 0.x Alpha
Hardware: All All
: P2 enhancement
Assignee: Odamex Bug Reporter
Depends on:
Blocks: 620
  Show dependency tree
Reported: 2008-04-19 15:35 UTC by Mike Lightner
Modified: 2014-03-20 00:23 UTC (History)
0 users

See Also:


Add an attachment (proposed patch, testcase, etc.)

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Lightner 2008-04-19 15:35:43 UTC
In order to support Rich Internet Application (RIA) interaction, it is necessary to have some method of instantiating odamex application services.  One convenient way to do this is via a URI.  

Currently, when one launches odamex via this URI method, odamex receives one argument that ends up being the entire URI itself, i.e.:


The above becomes argv[0] and argc is 1.  Odamex should parse these into a form it can digest.  Likewise this could be done with launching odasrv:

odasrv:///?+hostname=abc def&port=10669 (third slash after colon to match above where location would be).
Comment 1 Denis Lukianov 2008-05-14 20:35:17 UTC
r751 client interprets argv[0] of the format "odamex://odamex.org:10666/"
Comment 2 Mike Lightner 2008-05-21 20:52:13 UTC
Tested r801, there's no feedback in the console and client just starts up as if nothing was passed to it.
Comment 3 Denis Lukianov 2008-05-21 23:57:20 UTC
what is your test?
Comment 4 Mike Lightner 2008-05-22 06:14:28 UTC
Two fold, using my existing registry setup that passes the url to odamex.exe as the only argument and manually invoking it by simply doing:

odamex.exe odamex://odamex.org:10666

Which is the same thing that the uri passing from the browser does.
Comment 5 Denis Lukianov 2008-05-22 09:41:48 UTC
that would be passed as argv[1], not argv[0]

argv[0] = "odamex.exe"
argv[1] = "odamex://odamex.org:10666"
Comment 6 Denis Lukianov 2008-05-22 09:59:26 UTC
the current version of the client also looks for the terminating '/'
Comment 7 Denis Lukianov 2008-05-22 10:13:51 UTC
r806 parses argv[1] instead of argv[0] and does not require the extra slash
Comment 8 Mike Lightner 2008-07-27 13:35:05 UTC
It does in fact do this.  Now, if it could then look for /? and parse everything after it as a set of args separated by & it'd be complete.