mldonkey-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Mldonkey-commits] mldonkey distrib/ChangeLog src/daemon/driver/dr...


From: mldonkey-commits
Subject: [Mldonkey-commits] mldonkey distrib/ChangeLog src/daemon/driver/dr...
Date: Sat, 21 Oct 2006 19:37:34 +0000

CVSROOT:        /sources/mldonkey
Module name:    mldonkey
Changes by:     spiralvoice <spiralvoice>       06/10/21 19:37:34

Modified files:
        distrib        : ChangeLog 
        src/daemon/driver: driverCommands.ml 

Log message:
        patch #5472

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/mldonkey/distrib/ChangeLog?cvsroot=mldonkey&r1=1.1055&r2=1.1056
http://cvs.savannah.gnu.org/viewcvs/mldonkey/src/daemon/driver/driverCommands.ml?cvsroot=mldonkey&r1=1.183&r2=1.184

Patches:
Index: distrib/ChangeLog
===================================================================
RCS file: /sources/mldonkey/mldonkey/distrib/ChangeLog,v
retrieving revision 1.1055
retrieving revision 1.1056
diff -u -b -r1.1055 -r1.1056
--- distrib/ChangeLog   21 Oct 2006 19:36:34 -0000      1.1055
+++ distrib/ChangeLog   21 Oct 2006 19:37:34 -0000      1.1056
@@ -15,6 +15,7 @@
 =========
 
 2006/10/21
+5472: Urladd: New optional parameter period (in hours) (thx to Schlumpf)
 5471: HTML: New colums for pending slots list: SUI, GeoIP, Filename
 5470: Options: New type percent_option, values are bound to be >= 0 and <= 100
 5469: HTML: Implement 404 error page for unknown URLs

Index: src/daemon/driver/driverCommands.ml
===================================================================
RCS file: /sources/mldonkey/mldonkey/src/daemon/driver/driverCommands.ml,v
retrieving revision 1.183
retrieving revision 1.184
diff -u -b -r1.183 -r1.184
--- src/daemon/driver/driverCommands.ml 21 Oct 2006 19:36:34 -0000      1.183
+++ src/daemon/driver/driverCommands.ml 21 Oct 2006 19:37:34 -0000      1.184
@@ -334,12 +334,18 @@
           _s "You are not allowed to kill MLDonkey"
         ), ":\t\t\t\t\t$bsave and kill the server$n";
 
-    "urladd", Arg_two (fun kind url o ->
-       web_infos_add kind 1 url;
+    "urladd", Arg_multiple (fun args o ->
+       let (kind, url, period) = match args with
+          | [kind; url; period] -> kind, url, int_of_string period
+          | [kind; url] -> kind, url, 1
+          | _  -> failwith "Bad number of arguments"
+        in
+       web_infos_add kind period url;
        CommonWeb.load_url true kind url;
         "url added to web_infos. downloading now"
-    ), "<kind> <url> :\t\t\tload this file from the web\n"
-       ^"\t\t\t\t\tkind is either server.met (if the downloaded file is a 
server.met)";
+    ), "<kind> <url> [<period>]:\t\t\tload this file from the web\n"
+       ^"\t\t\t\t\tkind is either server.met (if the downloaded file is a 
server.met)\n"
+       ^"\t\t\t\t\tperiod is the period between updates (in hours, 0 = only 
loaded at startup)";
 
     "urlremove", Arg_one (fun url o ->
        if web_infos_exists url then
@@ -1821,7 +1827,7 @@
 \\<table cellspacing=0 cellpadding=0  width=100%%\\>\\<tr\\>
 \\<td class=downloaded width=100%%\\>\\</td\\>
 \\<td nowrap class=\\\"fbig pr\\\"\\>\\<a onclick=\\\"javascript: {
-                   var getdir = prompt('Input: <kind> <URL>','server.met URL')
+                   var getdir = prompt('Input: <kind> <URL> 
[<period>]','server.met URL')
                    parent.fstatus.location.href='submit?q=urladd+' + 
encodeURIComponent(getdir);
                    setTimeout('window.location.reload()',1000);
                     }\\\"\\>Add URL\\</a\\>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]