Article delegate-en/2987 of [1-5169] on the server localhost:119
  upper oldest olders older1 this newer1 newers latest
search
[Top/Up] [oldest] - [Older+chunk] - [Newer+chunk] - [newest + Check]
[Reference:<_A2986@delegate-en.ML_>]
Newsgroups: mail-lists.delegate-en

[DeleGate-En] Re: news proxy cannot cashe ?
23 Jun 2005 16:11:09 GMT feedback@delegate.org (Yutaka Sato)
The DeleGate Project


Hi,

In message <_A2986@delegate-en.ML_> on 06/22/05(19:29:48)
you "damir" <pbmfqbdyi-fjxi26b46qlr.ml@ml.delegate.org> wrote:
 |> Your LOGFILE is expected to have recorded the reason or hints of
 |> the error.  Running DeleGate with "-vd" and "-W" options will make
 |> the log more detailed.
...
 |D:\/delegate11-news.readfreenews.net/cache/nntp/news.readfreenews.net:120/LI
 |ST/active
 |06/22 11:56:54.31 [8520] 1+0:
 |dirfopen(\/delegate11-news.readfreenews.net/cache/nntp/news.readfreenews.net
 |..120/LIST/active,w+): 0 [-1]
...
 |06/22 11:56:54.31 [8520] 1+0: CACHE:
 |`D:\/delegate11-news.readfreenews.net/cache/$[server:%P/%L/%p]'
 |06/22 11:56:54.31 [8520] 1+0: CACHE:
 |`D:\/delegate11-news.readfreenews.net/cache/nntp/news.readfreenews.net:120/l
 |ib/pathhost'
...
 |Also when I look that other delegate work normaly and this was not cache ...
 |for me it look that is some bug in delegate ... try this server yourself  it
 |is free :news.readfreenews.net:120
 |only difrent is that this server is read only ... not allow posting and his
 |run on 120 port and it look that delegate because this 120 cannot create
 |cache direcories ..

Oh, I see.  So the problem is generic one which is caused when a
server is at non-standard port number, where the file path includes
":portnumber" which must be escaped on Win32.
I fixed it as the enclosed patch and uploaded the patched version
as 9.0.3-pre21 at <ftp://ftp.delegate.org/pub/DeleGate/alpha/>
(source and Win32 binary)

Cheers,
Yutaka
--
  D G   Yutaka Sato <y.sato@delegate.org> http://delegate.org/y.sato/
 ( - )  National Institute of Advanced Industrial Science and Technology
_<   >_ 1-1-4 Umezono, Tsukuba, Ibaraki, 305-8568 Japan
Do the more with the less -- B. Fuller


diff -cr delegate9.0.3-pre20/rary/file.c delegate9.0.3-pre21/rary/file.c
*** delegate9.0.3-pre20/rary/file.c	Thu Jan 20 04:20:39 2005
--- delegate9.0.3-pre21/rary/file.c	Thu Jun 23 23:02:52 2005
***************
*** 732,737 ****
--- 732,738 ----
  		return;
  
  	buff = stralloc(path);
+ 	dp = path;
  	for( sp = buff; sc = *sp; sp++ ){
  		assertVStr(path,dp+3);
  		if( sc == '.' && sp[1] == '/' ){
diff -cr delegate9.0.3-pre20/src/enews.c delegate9.0.3-pre21/src/enews.c
*** delegate9.0.3-pre20/src/enews.c	Tue Apr 26 23:26:56 2005
--- delegate9.0.3-pre21/src/enews.c	Fri Jun 24 00:54:01 2005
***************
*** 59,64 ****
--- 59,76 ----
  	XsetVStrEnd(AVStr(gp),0);
  }
  
+ FILE *news_fopen(const char *F,int L,const char *file,const char *mode){
+ 	FILE *fp;
+ 	CStr(xfile,1024);
+ 
+ 	strcpy(xfile,file);
+ 	path_escchar(AVStr(xfile));
+ 	fp = fopen(xfile,mode);
+ 	return fp;
+ }
+ #undef fopen
+ #define fopen(file,mode) news_fopen(__FILE__,__LINE__,file,mode)
+ 
  static FILE *fopen_active(PCStr(group),PCStr(mode1),PCStr(mode2))
  {	CStr(actpath1,LINESIZE);
  	CStr(apath,LINESIZE);
diff -cr delegate9.0.3-pre20/src/nntp.c delegate9.0.3-pre21/src/nntp.c
*** delegate9.0.3-pre20/src/nntp.c	Wed Jun 22 09:48:22 2005
--- delegate9.0.3-pre21/src/nntp.c	Thu Jun 23 23:28:44 2005
***************
*** 26,31 ****
--- 26,35 ----
  #include "file.h"
  #include "auth.h"
  
+ #undef fopen
+ #define fopen(file,mode) news_fopen(__FILE__,__LINE__,file,mode)
+ FILE *news_fopen(const char *F,int L,const char *file,const char *mode);
+ 
  void ENEWS_addspool(PCStr(dir),int recursive);
  FILE *ENEWS_article(PCStr(msgid),PCStr(group),int anum);
  int ENEWS_group(PCStr(group),int *total,int *min,int *max);

  admin search upper oldest olders older1 this newer1 newers latest
[Top/Up] [oldest] - [Older+chunk] - [Newer+chunk] - [newest + Check]
@_@V