diff --git a/trunk/ripnews/net/nntp.rb b/trunk/ripnews/net/nntp.rb index 73762ba..f89f437 100644 --- a/trunk/ripnews/net/nntp.rb +++ b/trunk/ripnews/net/nntp.rb @@ -135,11 +135,11 @@ class NNTP end def newgroups(date, time) - return longcmd "NEWGROUPS #{date.to_s} #{time.to_s}" + return longcmd("NEWGROUPS #{date.to_s} #{time.to_s}") end def newnews(group, date, time) - return longcmd "NEWNEWS #{group} #{date.to_s} #{time.to_s}" + return longcmd("NEWNEWS #{group} #{date.to_s} #{time.to_s}") end def list @@ -172,7 +172,7 @@ class NNTP end def help - return longcmd "HELP" + return longcmd("HELP") end def statparse(resp) @@ -196,15 +196,15 @@ class NNTP end def stat(id) - return statcmd "STAT #{id}" + return statcmd("STAT #{id}") end def next - return statcmd "NEXT" + return statcmd("NEXT") end def last - return statcmd "LAST" + return statcmd("LAST") end def articlecmd(line) @@ -214,19 +214,19 @@ class NNTP end def head(id) - return articlecmd "HEAD #{id}" + return articlecmd("HEAD #{id}") end def body(id) - return articlecmd "BODY #{id}" + return articlecmd("BODY #{id}") end def article(id) - return articlecmd "ARTICLE #{id}" + return articlecmd("ARTICLE #{id}") end def slave(id) - return shortcmd "SLAVE" + return shortcmd("SLAVE") end def xhdr(hdr, str) @@ -251,7 +251,7 @@ class NNTP } return resp, xover_lines rescue RuntimeError - raise NNTPDataError line, caller + raise(NNTPDataError, line, caller) end end @@ -273,7 +273,7 @@ class NNTP raise NNTPDataError unless resp.length == 2 date = resp[1][2...8] time = resp[1][-6..-1] - raise NNTPDataError resp, caller unless date.length == 6 and time.length == 6 + raise(NNTPDataError, resp, caller) unless date.length == 6 and time.length == 6 return resp, date, time end