lib_4.0C_1.fix
上传用户:zlh9724
上传日期:2007-01-04
资源大小:1991k
文件大小:128k
源码类别:

浏览器

开发平台:

Unix_Linux

  1.        HTNet *srcnet = request->source->net;
  2. !      if (srcnet) {
  3. !  HTEvent_Register(srcnet->sockfd, request->source,
  4. !   (SockOps) FD_READ,
  5. !   srcnet->cbf, srcnet->priority);
  6. !  HTEvent_UnRegister(net->sockfd, FD_WRITE);
  7. !      }
  8.        return HT_OK;
  9.    }
  10.    status = request->PostCallback ?
  11. --- 594,603 ----
  12.        if (ops == FD_WRITE || ops == FD_NONE) {
  13.    if (HTRequest_isDestination(request)) {
  14.        HTNet *srcnet = request->source->net;
  15. !      TTYPrint(TDEST,"File Serve. HERE!n");
  16. !      HTEvent_Register(srcnet->sockfd, request->source,
  17. !       (SockOps) FD_READ,
  18. !       srcnet->cbf, srcnet->priority);
  19.        return HT_OK;
  20.    }
  21.    status = request->PostCallback ?
  22. ***************
  23. *** 609,614 ****
  24. --- 613,620 ----
  25.        return HT_OK;
  26.    else if (status == HT_LOADED)
  27.        http->state = http->next;        /* Jump to next state */
  28. +  else if (status == HT_RELOAD)
  29. +      http->state = HTTP_EXPIRED;
  30.    else
  31.        http->state = HTTP_ERROR;
  32.        } else {
  33. ***************
  34. *** 620,719 ****
  35.        http->state = HTTP_ERROR;
  36.        break;
  37.   
  38. !    case HTTP_PERM_REDIRECT:
  39. !      if (HTRequest_isPostWeb(request)) {
  40. !  if (HTRequest_isDestination(request)) {
  41. !      HTLink *link =
  42. !  HTAnchor_findLink((HTAnchor *) request->source->anchor,
  43. !    (HTAnchor *) anchor);
  44. !      HTLink_setResult(link, HT_LINK_ERROR);
  45. !  }
  46.    HTRequest_killPostWeb(request);
  47. !      }
  48. !      HTTPCleanup(request, HT_PERM_REDIRECT);
  49. !      return HT_OK;
  50. !      break;
  51.   
  52. !    case HTTP_TEMP_REDIRECT:
  53. !      if (HTRequest_isPostWeb(request)) {
  54. !  if (HTRequest_isDestination(request)) {
  55. !      HTLink *link =
  56. !  HTAnchor_findLink((HTAnchor *) request->source->anchor,
  57. !    (HTAnchor *) anchor);
  58. !      HTLink_setResult(link, HT_LINK_ERROR);
  59.    }
  60. !  HTRequest_killPostWeb(request);
  61.        }
  62. -      HTTPCleanup(request, HT_TEMP_REDIRECT);
  63. -      return HT_OK;
  64.        break;
  65.      case HTTP_AA:
  66. !      if (HTRequest_isPostWeb(request)) {
  67. !  if (HTRequest_isDestination(request)) {
  68. !      HTLink *link =
  69. !  HTAnchor_findLink((HTAnchor *) request->source->anchor,
  70. !    (HTAnchor *) anchor);
  71. !      HTLink_setResult(link, HT_LINK_ERROR);
  72. !  }
  73.    HTRequest_killPostWeb(request);
  74.        }
  75. -      HTTPCleanup(request, HT_NO_ACCESS);
  76. -      return HT_OK;
  77.        break;
  78.      case HTTP_GOT_DATA:
  79.        if (HTRequest_isPostWeb(request)) {
  80.    if (HTRequest_isDestination(request)) {
  81.        HTLink *link =
  82.    HTAnchor_findLink((HTAnchor *) request->source->anchor,
  83. !    (HTAnchor *) anchor);
  84.        HTLink_setResult(link, HT_LINK_OK);
  85.    }
  86. !      }
  87. !      HTTPCleanup(request, HT_LOADED);
  88.        return HT_OK;
  89.        break;
  90.        
  91.      case HTTP_NO_DATA:
  92.        if (HTRequest_isPostWeb(request)) {
  93.    if (HTRequest_isDestination(request)) {
  94.        HTLink *link =
  95.    HTAnchor_findLink((HTAnchor *) request->source->anchor,
  96. !    (HTAnchor *) anchor);
  97.        HTLink_setResult(link, HT_LINK_OK);
  98.    }
  99. !      }
  100. !      HTTPCleanup(request, HT_NO_DATA);
  101.        return HT_OK;
  102.        break;
  103.        
  104.      case HTTP_RETRY:
  105.        if (HTRequest_isPostWeb(request)) {
  106.    if (HTRequest_isDestination(request)) {
  107.        HTLink *link = 
  108.    HTAnchor_findLink((HTAnchor*) request->source->anchor,
  109. !    (HTAnchor*) anchor);
  110.        HTLink_setResult(link, HT_LINK_ERROR);
  111.    }
  112. !  HTRequest_killPostWeb(request);
  113. !      }
  114. !      HTTPCleanup(request, HT_RETRY);
  115.        return HT_OK;
  116.        break;
  117.   
  118.      case HTTP_ERROR:
  119.        if (HTRequest_isPostWeb(request)) {
  120.    if (HTRequest_isDestination(request)) {
  121.        HTLink *link =
  122.    HTAnchor_findLink((HTAnchor *) request->source->anchor,
  123. !    (HTAnchor *) anchor);
  124.        HTLink_setResult(link, HT_LINK_ERROR);
  125.    }
  126. !  HTRequest_killPostWeb(request);
  127. !      }
  128. !      HTTPCleanup(request, HT_ERROR);
  129.        return HT_OK;
  130.        break;
  131.    }
  132. --- 626,821 ----
  133.        http->state = HTTP_ERROR;
  134.        break;
  135.   
  136. !    case HTTP_EXPIRED:
  137. ! #if 0
  138. !      /* Dirty hack and fall through */
  139. !      if (PROT_TRACE) TTYPrint(TDEST, "HTTP........ Expiredn");
  140. !      request->redirect = request->anchor->address;
  141. ! #endif
  142. !    case HTTP_REDIRECTION:
  143. !      /* Clean up the other connections or just this one */
  144. !      if (HTRequest_isPostWeb(request))
  145.    HTRequest_killPostWeb(request);
  146. !      else
  147. !  HTTPCleanup(request, HT_IGNORE);
  148.   
  149. !      /* If we found a new URL in the response */
  150. !      if (request->redirect) {
  151. !  if (status == 301) {
  152. !      HTRequest_addError(request, ERR_INFO, NO, HTERR_MOVED,
  153. !         (void *) request->redirect,
  154. !         (int) strlen(request->redirect), "HTLoadHTTP");
  155. !  } else if (status == 302) {
  156. !      HTRequest_addError(request, ERR_INFO, NO, HTERR_FOUND,
  157. !         (void *) request->redirect,
  158. !         (int) strlen(request->redirect), "HTLoadHTTP");
  159. !  }
  160. !  /* If we haven't reached the limit for redirection */
  161. !  if (HTRequest_retry(request)) {
  162. !      HTAlertCallback *cbf = HTAlert_find(HT_A_CONFIRM);
  163. !      HTAnchor *anchor = HTAnchor_findAddress(request->redirect);
  164. !      /* Make sure that we don't get this from cache */
  165. !      HTRequest_setReloadMode(request, HT_FORCE_RELOAD);
  166. !      
  167. !      if (HTRequest_isPostWeb(request)) {
  168. !  HTRequest *dest = HTRequest_mainDestination(request);
  169. !  if (cbf && (*cbf)(request, HT_A_CONFIRM, HT_MSG_MOVED,
  170. !    NULL, request->redirect, NULL)) {
  171. !      /* The new anchor inherits the Post Web */
  172. !      HTAnchor_moveAllLinks((HTAnchor *) request->anchor,
  173. !    anchor);
  174. !      if (HTRequest_isSource(request))
  175. !  HTRequest_delete(request);
  176. !      return HTCopyAnchor((HTAnchor *) anchor, dest) ?
  177. !  HT_OK : HT_ERROR;
  178. !  }
  179. !  return HT_OK;
  180. !      } if (request->PostCallback) {
  181. ! #if 0
  182. !  return HTUploadAnchor((HTAnchor*) anchor, request) ?
  183. !      HT_OK : HT_ERROR;
  184. ! #endif
  185. !      } else {
  186. !  return HTLoadAnchor((HTAnchor *) anchor, request) ?
  187. !      HT_OK : HT_ERROR;
  188. !      }
  189. !  } else {
  190. !      HTRequest_addError(request, ERR_FATAL, NO,
  191. !         HTERR_MAX_REDIRECT,NULL,0,"HTLoadHTTP");
  192. !      if (HTRequest_isPostWeb(request)) {
  193. !  BOOL main = HTRequest_isMainDestination(request);
  194. !  if (HTRequest_isDestination(request)) {
  195. !      HTLink *link =
  196. !  HTAnchor_findLink((HTAnchor *)request->source->anchor,
  197. !    (HTAnchor *)request->anchor);
  198. !      HTLink_setResult(link, HT_LINK_ERROR);
  199. !  }
  200. !  HTNet_callAfter(request, main ? HT_ERROR : HT_IGNORE);
  201. !  HTRequest_removeDestination(request);
  202. !      }
  203. !      return HT_OK;
  204.    }
  205. !      } else {
  206. !  HTRequest_addError(request, ERR_FATAL, NO, HTERR_BAD_REPLY,
  207. !     NULL, 0, "HTLoadHTTP");
  208. !  return HT_OK;
  209.        }
  210.        break;
  211. !      
  212.      case HTTP_AA:
  213. !      /* Clean up the other connections or just this one */
  214. !      if (HTRequest_isPostWeb(request))
  215.    HTRequest_killPostWeb(request);
  216. +      else
  217. +  HTTPCleanup(request, HT_IGNORE);
  218. +      /* Ask the user for a UserID and a passwd */
  219. +      if (HTTPAuthentication(request) && HTAA_retryWithAuth(request)) {
  220. +  int ret;
  221. +  /* Make sure that we don't get this from cache */
  222. +  HTRequest_setReloadMode(request, HT_FORCE_RELOAD);
  223. +  if (HTRequest_isPostWeb(request)) {
  224. +      HTRequest *dest = HTRequest_mainDestination(request);
  225. +      HTAnchor_appendMethods(request->anchor, request->method);
  226. +      ret=HTCopyAnchor((HTAnchor*)request->source->anchor, dest);
  227. +      return ret ? HT_OK : HT_ERROR;
  228. +  } else if (request->PostCallback) {
  229. + #if 0
  230. +      ret = HTUploadAnchor((HTAnchor*) request->anchor,request);
  231. +      return ret ? HT_OK : HT_ERROR;
  232. + #endif
  233. +  } else {
  234. +      ret = HTLoadAnchor((HTAnchor *) request->anchor, request);
  235. +      return ret ? HT_OK : HT_ERROR;
  236. +  }
  237. +      } else {    /* If the guy said no :-( */
  238. +  HTRequest_addError(request, ERR_FATAL, NO, HTERR_UNAUTHORIZED,
  239. +     NULL, 0, "HTLoadHTTP");
  240. +  if (HTRequest_isPostWeb(request)) {
  241. +      BOOL main = HTRequest_isMainDestination(request);
  242. +      if (HTRequest_isDestination(request)) {
  243. +  HTLink *link =
  244. +      HTAnchor_findLink((HTAnchor *) request->source->anchor,
  245. +        (HTAnchor *) request->anchor);
  246. +  HTLink_setResult(link, HT_LINK_ERROR);
  247. +      }
  248. +      HTNet_callAfter(request, main ? HT_ERROR : HT_IGNORE);
  249. +      HTRequest_removeDestination(request);
  250. +  }
  251. +  return HT_OK;
  252.        }
  253.        break;
  254. !      
  255.      case HTTP_GOT_DATA:
  256.        if (HTRequest_isPostWeb(request)) {
  257. +  HTTPCleanup(request, HTRequest_isMainDestination(request) ?
  258. +      HT_LOADED : HT_IGNORE);
  259.    if (HTRequest_isDestination(request)) {
  260.        HTLink *link =
  261.    HTAnchor_findLink((HTAnchor *) request->source->anchor,
  262. !    (HTAnchor *) request->anchor);
  263.        HTLink_setResult(link, HT_LINK_OK);
  264.    }
  265. !  HTRequest_removeDestination(request);
  266. !      } else
  267. !  HTTPCleanup(request, HT_LOADED);
  268.        return HT_OK;
  269.        break;
  270.        
  271.      case HTTP_NO_DATA:
  272.        if (HTRequest_isPostWeb(request)) {
  273. +  HTTPCleanup(request, HTRequest_isMainDestination(request) ?
  274. +      HT_NO_DATA : HT_IGNORE);
  275.    if (HTRequest_isDestination(request)) {
  276.        HTLink *link =
  277.    HTAnchor_findLink((HTAnchor *) request->source->anchor,
  278. !    (HTAnchor *) request->anchor);
  279.        HTLink_setResult(link, HT_LINK_OK);
  280.    }
  281. !  HTRequest_removeDestination(request);
  282. !      } else
  283. !  HTTPCleanup(request, HT_NO_DATA);
  284.        return HT_OK;
  285.        break;
  286.        
  287.      case HTTP_RETRY:
  288.        if (HTRequest_isPostWeb(request)) {
  289. +  HTTPCleanup(request, HTRequest_isMainDestination(request) ?
  290. +      HT_RETRY : HT_IGNORE);
  291. +  HTRequest_killPostWeb(request);
  292.    if (HTRequest_isDestination(request)) {
  293.        HTLink *link = 
  294.    HTAnchor_findLink((HTAnchor*) request->source->anchor,
  295. !    (HTAnchor*) request->anchor);
  296.        HTLink_setResult(link, HT_LINK_ERROR);
  297.    }
  298. !  HTRequest_removeDestination(request);
  299. !      } else
  300. !  HTTPCleanup(request, HT_RETRY);
  301.        return HT_OK;
  302.        break;
  303.   
  304.      case HTTP_ERROR:
  305. +      /* Clean up the other connections or just this one */
  306.        if (HTRequest_isPostWeb(request)) {
  307. +  HTTPCleanup(request, HTRequest_isMainDestination(request) ?
  308. +      HT_ERROR : HT_IGNORE);
  309. +  HTRequest_killPostWeb(request);
  310.    if (HTRequest_isDestination(request)) {
  311.        HTLink *link =
  312.    HTAnchor_findLink((HTAnchor *) request->source->anchor,
  313. !    (HTAnchor *) request->anchor);
  314.        HTLink_setResult(link, HT_LINK_ERROR);
  315.    }
  316. !  HTRequest_removeDestination(request);
  317. !      } else
  318. !  HTTPCleanup(request, HT_ERROR);
  319.        return HT_OK;
  320.        break;
  321.    }
  322. diff -c Library/Repository/Implementation/HTTPRes.c:2.2.2.1 Library/Repository/Implementation/HTTPRes.c:2.2
  323. *** Library/Repository/Implementation/HTTPRes.c:2.2.2.1 Tue Jan 23 16:31:36 1996
  324. --- Library/Repository/Implementation/HTTPRes.c Tue Jan 23 16:31:36 1996
  325. ***************
  326. *** 76,81 ****
  327. --- 76,82 ----
  328.   PRIVATE void HTTPMakeResponse (HTStream * me, HTRequest * request)
  329.   {
  330.       char linebuf[256];
  331. +     HTParentAnchor *anchor = HTRequest_anchor(request);
  332.   
  333.       /* Generate the HTTP/1.0 ResponseLine */
  334.       if (request->error_stack) {
  335. diff -c Library/Repository/Implementation/HTTPServ.c:2.4.2.1 Library/Repository/Implementation/HTTPServ.c:2.4
  336. *** Library/Repository/Implementation/HTTPServ.c:2.4.2.1 Tue Jan 23 16:31:37 1996
  337. --- Library/Repository/Implementation/HTTPServ.c Tue Jan 23 16:31:37 1996
  338. ***************
  339. *** 102,108 ****
  340.   PRIVATE int ParseRequest (HTStream * me)
  341.   {
  342.       HTRequest * request = me->request;
  343. !     HTRequest * newreq = me->http->serve = HTRequest_dupInternal(request);
  344.       char * line = HTChunk_data(me->buffer);
  345.       char * method;
  346.       char * request_uri;
  347. --- 102,108 ----
  348.   PRIVATE int ParseRequest (HTStream * me)
  349.   {
  350.       HTRequest * request = me->request;
  351. !     HTRequest * newreq = me->http->serve = HTRequest_dup(request);
  352.       char * line = HTChunk_data(me->buffer);
  353.       char * method;
  354.       char * request_uri;
  355. diff -c Library/Repository/Implementation/HTUtils.html:2.51.2.1 Library/Repository/Implementation/HTUtils.html:2.51
  356. *** Library/Repository/Implementation/HTUtils.html:2.51.2.1 Tue Jan 23 16:31:37 1996
  357. --- Library/Repository/Implementation/HTUtils.html Tue Jan 23 16:31:37 1996
  358. ***************
  359. *** 1,7 ****
  360.   <HTML>
  361.   <HEAD>
  362.   <TITLE>Utility macros</TITLE>
  363. ! <!-- Changed by: Henrik Frystyk Nielsen, 20-Jan-1996 -->
  364.   </HEAD>
  365.   <BODY>
  366.   
  367. --- 1,7 ----
  368.   <HTML>
  369.   <HEAD>
  370.   <TITLE>Utility macros</TITLE>
  371. ! <!-- Changed by: Henrik Frystyk Nielsen, 14-Jan-1996 -->
  372.   </HEAD>
  373.   <BODY>
  374.   
  375. ***************
  376. *** 277,287 ****
  377.   #define HT_OK 0 /* Generic success */
  378.   #define HT_ALL 1 /* Used by Net Manager */
  379.   
  380. ! #define HT_PERSISTENT 29993 /* Wait for persistent connection */
  381. ! #define HT_IGNORE 29994 /* Ignore this in the Net manager */
  382. ! #define HT_NO_DATA 29995 /* OK but no data was loaded */
  383. ! #define HT_PERM_REDIRECT 29997 /* Redo the retrieve with a new URL */
  384. ! #define HT_TEMP_REDIRECT 29998 /* Redo the retrieve with a new URL */
  385.   #define HT_LOADED 29999 /* Instead of a socket */
  386.   
  387.   #define HT_ERROR -1 /* Generic failure */
  388. --- 277,287 ----
  389.   #define HT_OK 0 /* Generic success */
  390.   #define HT_ALL 1 /* Used by Net Manager */
  391.   
  392. ! #define HT_PERSISTENT 29995 /* Wait for persistent connection */
  393. ! #define HT_IGNORE 29996 /* Ignore this in the Net manager */
  394. ! #define HT_NO_DATA 29997 /* OK but no data was loaded */
  395. ! #define HT_REDIRECTION_ON_FLY   29998 /* Redo the retrieve with a new URL */
  396. ! #define HT_REDIRECT 29998 /* Redo the retrieve with a new URL */
  397.   #define HT_LOADED 29999 /* Instead of a socket */
  398.   
  399.   #define HT_ERROR -1 /* Generic failure */
  400. diff -c Library/Repository/Implementation/HTWriter.c:2.27.4.1 Library/Repository/Implementation/HTWriter.c:2.27
  401. *** Library/Repository/Implementation/HTWriter.c:2.27.4.1 Tue Jan 23 16:31:38 1996
  402. --- Library/Repository/Implementation/HTWriter.c Tue Jan 23 16:31:38 1996
  403. ***************
  404. *** 18,24 ****
  405.   #include "HTReq.h"
  406.   #include "HTNetMan.h"
  407.   #include "HTConLen.h"
  408. - #include "HTAlert.h"
  409.   #include "HTWriter.h"  /* Implemented here */
  410.   
  411.   struct _HTStream {
  412. --- 18,23 ----
  413. ***************
  414. *** 69,76 ****
  415.   {
  416.       int b_write;
  417.       CONST char *limit = buf+len;
  418. -     HTRequest * request = me->net->request;
  419. -     HTNet * net = me->net;
  420.   
  421.   #ifdef NOT_ASCII
  422.       if (me->make_ascii && len && !me->ascbuf) {       /* Generate new buffer */
  423. --- 68,73 ----
  424. ***************
  425. *** 104,116 ****
  426.   #endif
  427.        {
  428.    if (PROT_TRACE)
  429. !      TTYPrint(TDEST,"Write Socket WOULD BLOCK %dn",me->sockfd);
  430. !  HTEvent_Register(me->sockfd, request, (SockOps) FD_WRITE,
  431. !   net->cbf, net->priority);
  432.    return HT_WOULD_BLOCK;
  433.        } else {
  434. !  HTRequest_addSystemError(request,  ERR_FATAL, socerrno, NO,
  435. !   "NETWRITE");
  436.    return HT_ERROR;
  437.        }
  438.    }
  439. --- 101,113 ----
  440.   #endif
  441.        {
  442.    if (PROT_TRACE)
  443. !      TTYPrint(TDEST,"Write Socket WOULD BLOCK %dn", me->sockfd);
  444. !  HTEvent_Register(me->sockfd,me->net->request,(SockOps)FD_WRITE,
  445. !   me->net->cbf, me->net->priority);
  446.    return HT_WOULD_BLOCK;
  447.        } else {
  448. !  if (PROT_TRACE)
  449. !      TTYPrint(TDEST, "Write Socket WRITE ERROR %dn", socerrno);
  450.    return HT_ERROR;
  451.        }
  452.    }
  453. ***************
  454. *** 120,130 ****
  455.    if (PROT_TRACE)
  456.        TTYPrint(TDEST, "Write Socket %d bytes written to socket %dn",
  457.        b_write, me->sockfd);
  458. -  net->bytes_written += b_write;
  459. -  {
  460. -      HTAlertCallback *cbf = HTAlert_find(HT_PROG_READ);
  461. -      if (cbf) (*cbf)(request, HT_PROG_WRITE,HT_MSG_NULL,NULL,NULL,NULL);
  462. -  }
  463.       }
  464.   #ifdef NOT_ASCII
  465.       FREE(me->ascbuf);
  466. --- 117,122 ----
  467. diff -c Library/Repository/Implementation/Version.make:1.47.2.1 Library/Repository/Implementation/Version.make:1.47
  468. *** Library/Repository/Implementation/Version.make:1.47.2.1 Tue Jan 23 16:31:39 1996
  469. --- Library/Repository/Implementation/Version.make Tue Jan 23 16:31:39 1996
  470. ***************
  471. *** 1 ****
  472. ! VC = 4.0C
  473. --- 1 ----
  474. ! VC = 4.0B
  475. diff -c Library/Repository/Implementation/windows/wwwcore.def:1.5.2.2 Library/Repository/Implementation/windows/wwwcore.def:1.5
  476. *** Library/Repository/Implementation/windows/wwwcore.def:1.5.2.2 Tue Jan 23 16:31:41 1996
  477. --- Library/Repository/Implementation/windows/wwwcore.def Tue Jan 23 16:31:42 1996
  478. ***************
  479. *** 190,208 ****
  480.   HTEvent_getWinHandle @ 1003
  481.   HTEvent_winHandle @ 1004
  482.   HTEvent_setWinHandle @ 1005
  483. ! HTEvent_getWinHandle @ 1006
  484. ! HTEvent_registerTimeout @ 1007
  485. ! HTEvent_unregisterTimeout @ 1008
  486. ! HTEvent_RegisterTTY @ 1009
  487. ! HTEvent_UnRegisterTTY @ 1010
  488. ! HTEvent_Register @ 1011
  489. ! HTEvent_UnRegister @ 1012
  490. ! HTEvent_Retrieve @ 1013
  491. ! HTEvent_UnregisterAll @ 1014
  492. ! AsyncWindowProc @ 1015
  493.   HTEvent_Loop @ 1016
  494. - AsyncWindowProc @ 1017
  495. - HTEvent_Loop @ 1018
  496.   
  497.   ;HTFormat.c @ 1100
  498.   HTPresentation_add @ 1101
  499. --- 190,206 ----
  500.   HTEvent_getWinHandle @ 1003
  501.   HTEvent_winHandle @ 1004
  502.   HTEvent_setWinHandle @ 1005
  503. ! HTEvent_registerTimeout @ 1006
  504. ! HTEvent_unregisterTimeout @ 1007
  505. ! HTEvent_RegisterTTY @ 1008
  506. ! HTEvent_UnRegisterTTY @ 1009
  507. ! HTEvent_Register @ 1010
  508. ! HTEvent_UnRegister @ 1011
  509. ! HTEvent_Retrieve @ 1012
  510. ! HTEvent_UnregisterAll @ 1013
  511. ! AsyncWindowProc @ 1014
  512. ! HTEvent_Loop @ 1015
  513.   HTEvent_Loop @ 1016
  514.   
  515.   ;HTFormat.c @ 1100
  516.   HTPresentation_add @ 1101
  517. ***************
  518. *** 295,377 ****
  519.   ;HTReqMan.c @ 1700
  520.   HTRequest_new @ 1701
  521.   HTRequest_dup @ 1702
  522. ! HTRequest_dupInternal @ 1703
  523. ! HTRequest_delete @ 1704
  524. ! HTRequest_setMethod @ 1705
  525. ! HTRequest_method @ 1706
  526. ! HTRequest_setReloadMode @ 1707
  527. ! HTRequest_reloadMode @ 1708
  528. ! HTRequest_setConversion @ 1709
  529. ! HTRequest_conversion @ 1710
  530. ! HTRequest_setEncoding @ 1711
  531. ! HTRequest_encoding @ 1712
  532. ! HTRequest_setLanguage @ 1713
  533. ! HTRequest_language @ 1714
  534. ! HTRequest_setCharset @ 1715
  535. ! HTRequest_charset @ 1716
  536. ! HTRequest_setGenerator @ 1717
  537. ! HTRequest_generator @ 1718
  538. ! HTRequest_setParser @ 1719
  539. ! HTRequest_parser @ 1720
  540. ! HTRequest_setGnHd @ 1721
  541. ! HTRequest_addGnHd @ 1722
  542. ! HTRequest_gnHd @ 1723
  543. ! HTRequest_setRqHd @ 1724
  544. ! HTRequest_addRqHd @ 1725
  545. ! HTRequest_rqHd @ 1726
  546. ! HTRequest_setRsHd @ 1727
  547. ! HTRequest_addRsHd @ 1728
  548. ! HTRequest_rsHd @ 1729
  549. ! HTRequest_setEnHd @ 1730
  550. ! HTRequest_addEnHd @ 1731
  551. ! HTRequest_enHd @ 1732
  552. ! HTRequest_setAccess @ 1733
  553. ! HTRequest_access @ 1734
  554. ! HTRequest_setAnchor @ 1735
  555. ! HTRequest_anchor @ 1736
  556. ! HTRequest_setParent @ 1737
  557. ! HTRequest_parent @ 1738
  558. ! HTRequest_setOutputStream @ 1739
  559. ! HTRequest_outputStream @ 1740
  560. ! HTRequest_setOutputFormat @ 1741
  561. ! HTRequest_outputFormat @ 1742
  562. ! HTRequest_setDebugStream @ 1743
  563. ! HTRequest_debugStream @ 1744
  564. ! HTRequest_setDebugFormat @ 1745
  565. ! HTRequest_debugFormat @ 1746
  566. ! HTRequest_setCallback @ 1747
  567. ! HTRequest_callback @ 1748
  568. ! HTRequest_setContext @ 1749
  569. ! HTRequest_context @ 1750
  570. ! HTRequest_setPreemtive @ 1751
  571. ! HTRequest_preemtive @ 1752
  572. ! HTRequest_setNegotiation @ 1753
  573. ! HTRequest_negotiation @ 1754
  574. ! HTRequest_bytesRead @ 1755
  575. ! HTRequest_bytesWritten @ 1756
  576. ! HTRequest_kill @ 1757
  577. ! HTRequest_error @ 1758
  578. ! HTRequest_setError @ 1759
  579. ! HTRequest_addError @ 1760
  580. ! HTRequest_addSystemError @ 1761
  581. ! HTRequest_retryTime @ 1762
  582. ! HTRequest_redirection @ 1763
  583. ! HTRequest_setMaxRetry @ 1764
  584. ! HTRequest_maxRetry @ 1765
  585. ! HTRequest_retry @ 1766
  586. ! HTRequest_setPriority @ 1767
  587. ! HTRequest_priority @ 1768
  588. ! HTRequest_setNet @ 1769
  589. ! HTRequest_net @ 1770
  590. ! HTRequest_addDestination @ 1771
  591. ! HTRequest_removeDestination @ 1772
  592. ! HTRequest_destinationsReady @ 1773
  593. ! HTRequest_linkDestination @ 1774
  594. ! HTRequest_unlinkDestination @ 1775
  595. ! HTRequest_removePostWeb @ 1776
  596. ! HTRequest_killPostWeb @ 1777
  597. ! HTLoad @ 1778
  598. ! HTServ @ 1779
  599.   
  600.   ;HTSocket.c @ 1800
  601.   HTInputSocket_new @ 1801
  602. --- 293,371 ----
  603.   ;HTReqMan.c @ 1700
  604.   HTRequest_new @ 1701
  605.   HTRequest_dup @ 1702
  606. ! HTRequest_delete @ 1703
  607. ! HTRequest_setMethod @ 1704
  608. ! HTRequest_method @ 1705
  609. ! HTRequest_setReloadMode @ 1706
  610. ! HTRequest_reloadMode @ 1707
  611. ! HTRequest_setConversion @ 1708
  612. ! HTRequest_conversion @ 1709
  613. ! HTRequest_setEncoding @ 1710
  614. ! HTRequest_encoding @ 1711
  615. ! HTRequest_setLanguage @ 1712
  616. ! HTRequest_language @ 1713
  617. ! HTRequest_setCharset @ 1714
  618. ! HTRequest_charset @ 1715
  619. ! HTRequest_setGenerator @ 1716
  620. ! HTRequest_generator @ 1717
  621. ! HTRequest_setParser @ 1718
  622. ! HTRequest_parser @ 1719
  623. ! HTRequest_setGnHd @ 1720
  624. ! HTRequest_addGnHd @ 1721
  625. ! HTRequest_gnHd @ 1722
  626. ! HTRequest_setRqHd @ 1723
  627. ! HTRequest_addRqHd @ 1724
  628. ! HTRequest_rqHd @ 1725
  629. ! HTRequest_setRsHd @ 1726
  630. ! HTRequest_addRsHd @ 1727
  631. ! HTRequest_rsHd @ 1728
  632. ! HTRequest_setEnHd @ 1729
  633. ! HTRequest_addEnHd @ 1730
  634. ! HTRequest_enHd @ 1731
  635. ! HTRequest_setAccess @ 1732
  636. ! HTRequest_access @ 1733
  637. ! HTRequest_setAnchor @ 1734
  638. ! HTRequest_anchor @ 1735
  639. ! HTRequest_setParent @ 1736
  640. ! HTRequest_parent @ 1737
  641. ! HTRequest_setOutputStream @ 1738
  642. ! HTRequest_outputStream @ 1739
  643. ! HTRequest_setOutputFormat @ 1740
  644. ! HTRequest_outputFormat @ 1741
  645. ! HTRequest_setDebugStream @ 1742
  646. ! HTRequest_debugStream @ 1743
  647. ! HTRequest_setDebugFormat @ 1744
  648. ! HTRequest_debugFormat @ 1745
  649. ! HTRequest_setCallback @ 1746
  650. ! HTRequest_callback @ 1747
  651. ! HTRequest_setContext @ 1748
  652. ! HTRequest_context @ 1749
  653. ! HTRequest_setPreemtive @ 1750
  654. ! HTRequest_preemtive @ 1751
  655. ! HTRequest_setNegotiation @ 1752
  656. ! HTRequest_negotiation @ 1753
  657. ! HTRequest_bytesRead @ 1754
  658. ! HTRequest_kill @ 1755
  659. ! HTRequest_error @ 1756
  660. ! HTRequest_setError @ 1757
  661. ! HTRequest_addError @ 1758
  662. ! HTRequest_addSystemError @ 1759
  663. ! HTRequest_retryTime @ 1760
  664. ! HTRequest_setMaxRetry @ 1761
  665. ! HTRequest_maxRetry @ 1762
  666. ! HTRequest_retry @ 1763
  667. ! HTRequest_setPriority @ 1764
  668. ! HTRequest_priority @ 1765
  669. ! HTRequest_setNet @ 1766
  670. ! HTRequest_net @ 1767
  671. ! HTRequest_addDestination @ 1768
  672. ! HTRequest_removeDestination @ 1769
  673. ! HTRequest_linkDestination @ 1770
  674. ! HTRequest_unlinkDestination @ 1771
  675. ! HTRequest_removePostWeb @ 1772
  676. ! HTRequest_killPostWeb @ 1773
  677. ! HTLoad @ 1774
  678. ! HTServ @ 1775
  679.   
  680.   ;HTSocket.c @ 1800
  681.   HTInputSocket_new @ 1801
  682. diff -c Library/Repository/Implementation/windows/wwwhttp.def:1.3.2.1 Library/Repository/Implementation/windows/wwwhttp.def:1.3
  683. *** Library/Repository/Implementation/windows/wwwhttp.def:1.3.2.1 Tue Jan 23 16:31:42 1996
  684. --- Library/Repository/Implementation/windows/wwwhttp.def Tue Jan 23 16:31:43 1996
  685. ***************
  686. *** 3,9 ****
  687.   HTAA_composeAuth @ 101
  688.   HTPasswordDialog @ 102
  689.   HTAA_retryWithAuth @ 103
  690. - HTAA_authentication @ 104
  691.   
  692.   ;HTAAUtil.c @ 200
  693.   HTAAScheme_enum @ 201
  694. --- 3,8 ----
  695. diff -c Library/Repository/Implementation/windows/wwwutils.def:1.4.2.1 Library/Repository/Implementation/windows/wwwutils.def:1.4
  696. *** Library/Repository/Implementation/windows/wwwutils.def:1.4.2.1 Tue Jan 23 16:31:43 1996
  697. --- Library/Repository/Implementation/windows/wwwutils.def Tue Jan 23 16:31:43 1996
  698. ***************
  699. *** 23,32 ****
  700.   HTChunk_clear @ 402
  701.   HTChunk_delete @ 403
  702.   HTChunk_putc @ 404
  703. ! HTChunk_ensure @ 405
  704. ! HTChunk_terminate @ 406
  705. ! HTChunk_puts @ 407
  706. ! HTChunk_putb @ 408
  707.   
  708.   ;HTList.c @ 500
  709.   HTList_new @ 501
  710. --- 23,32 ----
  711.   HTChunk_clear @ 402
  712.   HTChunk_delete @ 403
  713.   HTChunk_putc @ 404
  714. ! HTChunk_puts @ 405
  715. ! HTChunk_putb @ 406
  716. ! HTChunk_ensure @ 407
  717. ! HTChunk_terminate @ 408
  718.   
  719.   ;HTList.c @ 500
  720.   HTList_new @ 501
  721. diff -c Library/Repository/User/ReleaseNotes.html:1.20 Library/Repository/User/ReleaseNotes.html:1.21
  722. *** Library/Repository/User/ReleaseNotes.html:1.20 Tue Jan 23 16:31:44 1996
  723. --- Library/Repository/User/ReleaseNotes.html Tue Jan 23 16:31:44 1996
  724. ***************
  725. *** 88,94 ****
  726.   HREF="../Implementation/WWWMIME.html">WWWMIME.html</A>, and <A
  727.   HREF="../Implementation/WWWFTP.html">WWWFTP.html</A> include files to be used by applications.
  728.   
  729. ! <LI>Changed functions with the name <CODE>preemtive</CODE> to <CODE>preemptive</CODE> it was a spelling mistake
  730.   </UL>
  731.   
  732.   <H2>Alpha Release 6, November 20 1995</H2>
  733. --- 88,94 ----
  734.   HREF="../Implementation/WWWMIME.html">WWWMIME.html</A>, and <A
  735.   HREF="../Implementation/WWWFTP.html">WWWFTP.html</A> include files to be used by applications.
  736.   
  737. ! <LI>Changed functions with the name <CODE>preemptive</CODE> to <CODE>preemptive</CODE> it was a spelling mistake
  738.   </UL>
  739.   
  740.   <H2>Alpha Release 6, November 20 1995</H2>
  741. diff -c Library/Repository/User/Architecture/Events.html:1.4 Library/Repository/User/Architecture/Events.html:1.5
  742. *** Library/Repository/User/Architecture/Events.html:1.4 Tue Jan 23 16:31:46 1996
  743. --- Library/Repository/User/Architecture/Events.html Tue Jan 23 16:31:46 1996
  744. ***************
  745. *** 23,31 ****
  746.   
  747.   <DL>
  748.   
  749. ! <DT><B>Base Mode (preemtive)</B>
  750.   
  751. ! <DD>In this mode all requests are handled in a preemtive way that does
  752.   not allow for any events to pause the execution of a thread or kill
  753.   it. This mode is in other words strictly single threaded and the major
  754.   difference between this mode and the next two modes is that all
  755. --- 23,31 ----
  756.   
  757.   <DL>
  758.   
  759. ! <DT><B>Base Mode (preemptive)</B>
  760.   
  761. ! <DD>In this mode all requests are handled in a preemptive way that does
  762.   not allow for any events to pause the execution of a thread or kill
  763.   it. This mode is in other words strictly single threaded and the major
  764.   difference between this mode and the next two modes is that all
  765. diff -c Library/Repository/User/Architecture/Threads.html:1.8 Library/Repository/User/Architecture/Threads.html:1.9
  766. *** Library/Repository/User/Architecture/Threads.html:1.8 Tue Jan 23 16:31:47 1996
  767. --- Library/Repository/User/Architecture/Threads.html Tue Jan 23 16:31:47 1996
  768. ***************
  769. *** 66,74 ****
  770.   the same TCP socket. Net objects can be used in three different ways:
  771.   
  772.   <OL>
  773. ! <LI>All requests are preemtive and all I/O is blocking
  774. ! <LI>Requests are non-preemtive managed by an <EM>internal</EM> event loop
  775. ! <LI>Requests are non-preemtive managed by an <EM>external</EM> event loop
  776.   </OL>
  777.   
  778.   The three modes are described in more detail in the section on <A HREF="Events.html">Internal and
  779. --- 66,74 ----
  780.   the same TCP socket. Net objects can be used in three different ways:
  781.   
  782.   <OL>
  783. ! <LI>All requests are preemptive and all I/O is blocking
  784. ! <LI>Requests are non-preemptive managed by an <EM>internal</EM> event loop
  785. ! <LI>Requests are non-preemptive managed by an <EM>external</EM> event loop
  786.   </OL>
  787.   
  788.   The three modes are described in more detail in the section on <A HREF="Events.html">Internal and
  789. diff -c Library/Repository/User/Architecture/choppy.html:1.17 Library/Repository/User/Architecture/choppy.html:1.18
  790. *** Library/Repository/User/Architecture/choppy.html:1.17 Tue Jan 23 16:31:48 1996
  791. --- Library/Repository/User/Architecture/choppy.html Tue Jan 23 16:31:48 1996
  792. ***************
  793. *** 747,755 ****
  794.   the same TCP socket. Net objects can be used in three different ways:
  795.   
  796.   <OL>
  797. ! <LI>All requests are preemtive and all I/O is blocking
  798. ! <LI>Requests are non-preemtive managed by an <EM>internal</EM> event loop
  799. ! <LI>Requests are non-preemtive managed by an <EM>external</EM> event loop
  800.   </OL>
  801.   
  802.   The three modes are described in more detail in the section on <A HREF="Events.html">Internal and
  803. --- 747,755 ----
  804.   the same TCP socket. Net objects can be used in three different ways:
  805.   
  806.   <OL>
  807. ! <LI>All requests are preemptive and all I/O is blocking
  808. ! <LI>Requests are non-preemptive managed by an <EM>internal</EM> event loop
  809. ! <LI>Requests are non-preemptive managed by an <EM>external</EM> event loop
  810.   </OL>
  811.   
  812.   The three modes are described in more detail in the section on <A HREF="Events.html">Internal and
  813. ***************
  814. *** 1048,1056 ****
  815.   
  816.   <DL>
  817.   
  818. ! <DT><B>Base Mode (preemtive)</B>
  819.   
  820. ! <DD>In this mode all requests are handled in a preemtive way that does
  821.   not allow for any events to pause the execution of a thread or kill
  822.   it. This mode is in other words strictly single threaded and the major
  823.   difference between this mode and the next two modes is that all
  824. --- 1048,1056 ----
  825.   
  826.   <DL>
  827.   
  828. ! <DT><B>Base Mode (preemptive)</B>
  829.   
  830. ! <DD>In this mode all requests are handled in a preemptive way that does
  831.   not allow for any events to pause the execution of a thread or kill
  832.   it. This mode is in other words strictly single threaded and the major
  833.   difference between this mode and the next two modes is that all
  834. diff -c Library/Repository/User/Patch/Overview.html:1.17.2.1 Library/Repository/User/Patch/Overview.html:1.17
  835. *** Library/Repository/User/Patch/Overview.html:1.17.2.1 Tue Jan 23 16:31:51 1996
  836. --- Library/Repository/User/Patch/Overview.html Tue Jan 23 16:31:51 1996
  837. ***************
  838. *** 1,7 ****
  839.   <HTML>
  840.   <HEAD>
  841.   <TITLE>Known Bugs in W3C Reference Library</TITLE>
  842. ! <!-- Changed by: Henrik Frystyk Nielsen, 18-Jan-1996 -->
  843.   </HEAD>
  844.   <BODY>
  845.   
  846. --- 1,7 ----
  847.   <HTML>
  848.   <HEAD>
  849.   <TITLE>Known Bugs in W3C Reference Library</TITLE>
  850. ! <!-- Changed by: Henrik Frystyk Nielsen,  8-Jan-1996 -->
  851.   </HEAD>
  852.   <BODY>
  853.   
  854. ***************
  855. *** 41,48 ****
  856.   <H2>Library 4.0</H2>
  857.   
  858.   <UL>
  859. - <LI><A HREF="lib_4.0_1.fix">SGML fix from Maciej Puzio for better error handling</A>
  860.   
  861.   <LI><A HREF="lib_4.0_bug_3.html">Generating DLLs under Windows using Borland compilers</A>
  862.   
  863. --- 41,46 ----
  864. diff -c Library/Repository/User/Using/Methods.html:1.6 Library/Repository/User/Using/Methods.html:1.7
  865. *** Library/Repository/User/Using/Methods.html:1.6 Tue Jan 23 16:31:54 1996
  866. --- Library/Repository/User/Using/Methods.html Tue Jan 23 16:31:54 1996
  867. ***************
  868. *** 1,7 ****
  869.   <HTML>
  870.   <HEAD>
  871.   <TITLE>Using - Access Modules</TITLE>
  872. ! <!-- Changed by: Henrik Frystyk Nielsen, 31-Oct-1995 -->
  873.   </HEAD>  
  874.   <BODY>
  875.   
  876. --- 1,7 ----
  877.   <HTML>
  878.   <HEAD>
  879.   <TITLE>Using - Access Modules</TITLE>
  880. ! <!-- Changed by: Henrik Frystyk Nielsen, 17-Jan-1996 -->
  881.   </HEAD>  
  882.   <BODY>
  883.   
  884. ***************
  885. *** 36,42 ****
  886.   
  887.   <PRE>
  888.   extern BOOL HTProtocol_add (CONST char *        scheme,
  889. !      BOOL preemtive,
  890.        HTEventCallBack * callback);
  891.   </PRE>
  892.   
  893. --- 36,42 ----
  894.   
  895.   <PRE>
  896.   extern BOOL HTProtocol_add (CONST char *        scheme,
  897. !      BOOL preemptive,
  898.        HTEventCallBack * callback);
  899.   </PRE>
  900.   
  901. ***************
  902. *** 48,58 ****
  903.   with the <A HREF="../../Implementation/HTTelnet.html">Telnet access module</A> which also can handle
  904.   <B>rlogin</B> and <B>tn3270</B> terminal sessions. <P>
  905.   
  906. ! The next argument describes to the Library whether it is capable of handling non-blocking sockets or
  907. ! not. This is normally a design decision when implementing the protocol module, and we will not
  908. ! stretch this argument anymore in this guide. The <A HREF="../Architecture/">Library Architecture</A>
  909. ! document discusses in more detail how a protocol module can be designed to support non-blocking
  910. ! sockets. <P>
  911.   
  912.   The last argument is the actual function name to call when a request has been issued and a protocol
  913.   module has been found associated with the access scheme used. Even though it is not clear at this
  914. --- 48,61 ----
  915.   with the <A HREF="../../Implementation/HTTelnet.html">Telnet access module</A> which also can handle
  916.   <B>rlogin</B> and <B>tn3270</B> terminal sessions. <P>
  917.   
  918. ! <A NAME="preemptive"></A>The <CODE>preemptive</CODE> argument describes to the Library whether it is
  919. ! capable of handling non-blocking sockets or not. This is normally a design decision when
  920. ! implementing the protocol module in that a module implemented for using blocking sockets normally
  921. ! can't use non-blocking sockets. However, the other way is often possible, and in some situations it
  922. ! is advantageous to use blocking sockets. The Library allows this to happen on a pr request basic as
  923. ! explained in the section <A HREF="Request.html#preemptive">"The Request Object"</A>. The <A
  924. ! HREF="../Architecture/">Library Architecture</A> document discusses in more detail how a protocol
  925. ! module can be designed to support non-blocking sockets. <P>
  926.   
  927.   The last argument is the actual function name to call when a request has been issued and a protocol
  928.   module has been found associated with the access scheme used. Even though it is not clear at this
  929. diff -c Library/Repository/User/Using/Net.html:1.2.2.1 Library/Repository/User/Using/Net.html:1.2
  930. *** Library/Repository/User/Using/Net.html:1.2.2.1 Tue Jan 23 16:31:54 1996
  931. --- Library/Repository/User/Using/Net.html Tue Jan 23 16:31:55 1996
  932. ***************
  933. *** 1,7 ****
  934.   <HTML>
  935.   <HEAD>
  936.   <TITLE>User Guide - Request Callback functions</TITLE>
  937. ! <!-- Changed by: Henrik Frystyk Nielsen, 21-Jan-1996 -->
  938.   <NEXTID N="z78">
  939.   </HEAD>
  940.   <BODY>
  941. --- 1,7 ----
  942.   <HTML>
  943.   <HEAD>
  944.   <TITLE>User Guide - Request Callback functions</TITLE>
  945. ! <!-- Changed by: Henrik Frystyk Nielsen, 12-Nov-1995 -->
  946.   <NEXTID N="z78">
  947.   </HEAD>
  948.   <BODY>
  949. ***************
  950. *** 55,74 ****
  951.   <DL>
  952.   <DT>HT_ERROR
  953.   <DD>An error occured
  954. - <DT>HT_INTERRUPTED
  955. - <DD>The request was interrupted
  956.   <DT>HT_LOADED
  957.   <DD>The document was loaded
  958.   <DT>HT_NO_DATA
  959.   <DD>OK, but no data
  960.   <DT>HT_RETRY
  961.   <DD>Retry request after at a later time
  962. ! <DT>HT_PERM_REDIRECT
  963. ! <DD>The request has been permanently redirected and we send back the new URL
  964. ! <DT>HT_TEMP_REDIRECT
  965. ! <DD>The request has been temporarily redirected and we send back the new URL
  966. ! <DT>HT_NO_ACCESS
  967. ! <DD>The request could not be fulfilled because it didn't contain sufficient credentials
  968.   </DL>
  969.   
  970.   When a callback function is registered, it may be registered with a status code for which it is to
  971. --- 55,68 ----
  972.   <DL>
  973.   <DT>HT_ERROR
  974.   <DD>An error occured
  975.   <DT>HT_LOADED
  976.   <DD>The document was loaded
  977.   <DT>HT_NO_DATA
  978.   <DD>OK, but no data
  979.   <DT>HT_RETRY
  980.   <DD>Retry request after at a later time
  981. ! <DT>HT_REDIRECT
  982. ! <DD>The request has been redirected and we send back the new URL
  983.   </DL>
  984.   
  985.   When a callback function is registered, it may be registered with a status code for which it is to
  986. diff -c Library/Repository/User/Using/Request.html:1.8 Library/Repository/User/Using/Request.html:1.9
  987. *** Library/Repository/User/Using/Request.html:1.8 Tue Jan 23 16:31:55 1996
  988. --- Library/Repository/User/Using/Request.html Tue Jan 23 16:31:55 1996
  989. ***************
  990. *** 1,7 ****
  991.   <HTML>
  992.   <HEAD>
  993.   <TITLE>Using the W3C Reference Library</TITLE>
  994. ! <!-- Changed by: Henrik Frystyk Nielsen,  4-Dec-1995 -->
  995.   </HEAD>  
  996.   <BODY>
  997.   
  998. --- 1,7 ----
  999.   <HTML>
  1000.   <HEAD>
  1001.   <TITLE>Using the W3C Reference Library</TITLE>
  1002. ! <!-- Changed by: Henrik Frystyk Nielsen, 17-Jan-1996 -->
  1003.   </HEAD>  
  1004.   <BODY>
  1005.   
  1006. ***************
  1007. *** 382,400 ****
  1008.   extern void *HTRequest_context (HTRequest *request);
  1009.   </PRE>
  1010.   
  1011. ! <H2>Preemtive or Non-preemtive Access</H2>
  1012.   
  1013. ! A access scheme is defined with a default for using either preemtive
  1014. ! (blocking I/O) or non-premitve (non-blocking I/O). This is basically a
  1015. ! result of the implementation of the protocol module itself. However,
  1016. ! if non-blocking I/O is the default then some times it is nice to be
  1017. ! able to set the mode to blocking instead. For example when loading the
  1018. ! first document (the home page) then blocking can be used instead of
  1019. ! non-blocking.
  1020.   
  1021.   <PRE>
  1022. ! extern void HTRequest_setPreemtive (HTRequest *request, BOOL mode);
  1023. ! extern BOOL HTRequest_preemtive (HTRequest *request);
  1024.   </PRE>
  1025.   
  1026.   <H2>Format Negotiation</H2>
  1027. --- 382,399 ----
  1028.   extern void *HTRequest_context (HTRequest *request);
  1029.   </PRE>
  1030.   
  1031. ! <A NAME="preemptive"><H2>Preemptive or Non-preemptive Access</H2></A>
  1032.   
  1033. ! A access scheme is registered with a default for using either preemptive (blocking I/O) or
  1034. ! non-premitve (non-blocking I/O). This is basically a result of the implementation of the protocol
  1035. ! module itself and is explained in the section <A HREF="Methods.html#preemptive">Registering Access
  1036. ! Schemes</A>. However, if non-blocking I/O is the default then some times it is nice to be able to
  1037. ! set the mode to blocking instead. For example when loading the first document (the home page) then
  1038. ! blocking can be used instead of non-blocking.
  1039.   
  1040.   <PRE>
  1041. ! extern void HTRequest_setPreemptive (HTRequest *request, BOOL mode);
  1042. ! extern BOOL HTRequest_preemptive (HTRequest *request);
  1043.   </PRE>
  1044.   
  1045.   <H2>Format Negotiation</H2>
  1046. diff -c Library/Repository/User/Using/Startup.html:1.10 Library/Repository/User/Using/Startup.html:1.11
  1047. *** Library/Repository/User/Using/Startup.html:1.10 Tue Jan 23 16:31:56 1996
  1048. --- Library/Repository/User/Using/Startup.html Tue Jan 23 16:31:56 1996
  1049. ***************
  1050. *** 200,206 ****
  1051.   
  1052.   <PRE>
  1053.   extern BOOL HTProtocol_add (const char *        name,
  1054. !      BOOL preemtive,
  1055.        HTEventCallBack * callback);
  1056.   </PRE>
  1057.   
  1058. --- 200,206 ----
  1059.   
  1060.   <PRE>
  1061.   extern BOOL HTProtocol_add (const char *        name,
  1062. !      BOOL preemptive,
  1063.        HTEventCallBack * callback);
  1064.   </PRE>
  1065.   
  1066. diff -c Library/Repository/User/Using/choppy.html:1.15 Library/Repository/User/Using/choppy.html:1.16
  1067. *** Library/Repository/User/Using/choppy.html:1.15 Tue Jan 23 16:31:57 1996
  1068. --- Library/Repository/User/Using/choppy.html Tue Jan 23 16:31:57 1996
  1069. ***************
  1070. *** 269,275 ****
  1071.   
  1072.   <PRE>
  1073.   extern BOOL HTProtocol_add (const char *        name,
  1074. !      BOOL preemtive,
  1075.        HTEventCallBack * callback);
  1076.   </PRE>
  1077.   
  1078. --- 269,275 ----
  1079.   
  1080.   <PRE>
  1081.   extern BOOL HTProtocol_add (const char *        name,
  1082. !      BOOL preemptive,
  1083.        HTEventCallBack * callback);
  1084.   </PRE>
  1085.   
  1086. ***************
  1087. *** 841,847 ****
  1088.   
  1089.   <PRE>
  1090.   extern BOOL HTProtocol_add (CONST char *        scheme,
  1091. !      BOOL preemtive,
  1092.        HTEventCallBack * callback);
  1093.   </PRE>
  1094.   
  1095. --- 841,847 ----
  1096.   
  1097.   <PRE>
  1098.   extern BOOL HTProtocol_add (CONST char *        scheme,
  1099. !      BOOL preemptive,
  1100.        HTEventCallBack * callback);
  1101.   </PRE>
  1102.   
  1103. ***************
  1104. *** 2169,2177 ****
  1105.   extern void *HTRequest_context (HTRequest *request);
  1106.   </PRE>
  1107.   
  1108. ! <H2>Preemtive or Non-preemtive Access</H2>
  1109.   
  1110. ! A access scheme is defined with a default for using either preemtive
  1111.   (blocking I/O) or non-premitve (non-blocking I/O). This is basically a
  1112.   result of the implementation of the protocol module itself. However,
  1113.   if non-blocking I/O is the default then some times it is nice to be
  1114. --- 2169,2177 ----
  1115.   extern void *HTRequest_context (HTRequest *request);
  1116.   </PRE>
  1117.   
  1118. ! <H2>Preemptive or Non-preemptive Access</H2>
  1119.   
  1120. ! A access scheme is defined with a default for using either preemptive
  1121.   (blocking I/O) or non-premitve (non-blocking I/O). This is basically a
  1122.   result of the implementation of the protocol module itself. However,
  1123.   if non-blocking I/O is the default then some times it is nice to be
  1124. ***************
  1125. *** 2180,2187 ****
  1126.   non-blocking.
  1127.   
  1128.   <PRE>
  1129. ! extern void HTRequest_setPreemtive (HTRequest *request, BOOL mode);
  1130. ! extern BOOL HTRequest_preemtive (HTRequest *request);
  1131.   </PRE>
  1132.   
  1133.   <H2>Format Negotiation</H2>
  1134. --- 2180,2187 ----
  1135.   non-blocking.
  1136.   
  1137.   <PRE>
  1138. ! extern void HTRequest_setPreemptive (HTRequest *request, BOOL mode);
  1139. ! extern BOOL HTRequest_preemptive (HTRequest *request);
  1140.   </PRE>
  1141.   
  1142.   <H2>Format Negotiation</H2>
  1143. diff -c LineMode/Repository/Defaults/Commands.html:1.9 LineMode/Repository/Defaults/Commands.html:1.10
  1144. *** LineMode/Repository/Defaults/Commands.html:1.9 Tue Jan 23 16:31:59 1996
  1145. --- LineMode/Repository/Defaults/Commands.html Tue Jan 23 16:31:59 1996
  1146. ***************
  1147. *** 1,7 ****
  1148.   <HTML>
  1149.   <HEAD>
  1150.   <TITLE>Line Mode Browser Commands</TITLE>
  1151. ! <!-- Changed by: Henrik Frystyk Nielsen, 14-Oct-1995 -->
  1152.   <NEXTID N="z17">
  1153.   </HEAD>
  1154.   <BODY>
  1155. --- 1,7 ----
  1156.   <HTML>
  1157.   <HEAD>
  1158.   <TITLE>Line Mode Browser Commands</TITLE>
  1159. ! <!-- Changed by: Henrik Frystyk Nielsen, 19-Jan-1996 -->
  1160.   <NEXTID N="z17">
  1161.   </HEAD>
  1162.   <BODY>
  1163. ***************
  1164. *** 122,127 ****
  1165. --- 122,142 ----
  1166.   server. The syntax is the same as for PUT.
  1167.   
  1168.   </DL>
  1169. + <H3>Delete a Document on a remote server</H3>
  1170. + You can also use the DELETE method i the Line Mode browser to remove a
  1171. + document on a remote HTTP server.
  1172. + <DL>
  1173. + <DT><A NAME="delete"><B>delete</B></A>
  1174. + <DD>Deletes a document (DELETE) on remote HTTP server. Example
  1175. + <PRE>
  1176. +  delete
  1177. +  URL to delete: http://www.w3.org
  1178. + </PRE>
  1179.   
  1180.   <H3>Killer Features</H3>
  1181.   
  1182. diff -c LineMode/Repository/Implementation/HTBrowse.c:1.107.2.1 LineMode/Repository/Implementation/HTBrowse.c:1.107
  1183. *** LineMode/Repository/Implementation/HTBrowse.c:1.107.2.1 Tue Jan 23 16:32:01 1996
  1184. --- LineMode/Repository/Implementation/HTBrowse.c Tue Jan 23 16:32:01 1996
  1185. ***************
  1186. *** 137,142 ****
  1187. --- 137,143 ----
  1188.   typedef struct _LineMode {
  1189.       HTRequest * request;
  1190.       HTParentAnchor * anchor;
  1191. +     HTParentAnchor * dest;  /* Destination for PUT etc. */
  1192.       struct timeval * tv; /* Timeout on socket */
  1193.       HTList * active;   /* List of acitve contexts */
  1194.       HTList * converters;
  1195. ***************
  1196. *** 163,169 ****
  1197.       LMState state;
  1198.       HTRequest * request;
  1199.       LineMode * lm;
  1200. -     HTParentAnchor * source;    /* The source if we are using PUT or POST */
  1201.   } Context;
  1202.   
  1203.   #ifndef WWW_WIN_WINDOW
  1204. --- 164,169 ----
  1205. ***************
  1206. *** 544,558 ****
  1207.        HTMethod_name(HTLink_method(link)), HTLink_result(link));
  1208.        doit = confirm(req, msg);
  1209.        free(msg);
  1210. !  } else {
  1211. !      HTAnchor_removeAllLinks((HTAnchor *) src);
  1212.        HTAnchor_link((HTAnchor *) src, (HTAnchor *) dest, NULL, method);
  1213. -  }
  1214.    if (doit) {
  1215. !      HTRequest * new_request = Thread_new(lm, YES, LM_UPDATE);
  1216. !      Context * new_context = (Context *) HTRequest_context(new_request);
  1217. !      new_context->source = src;
  1218. !      status = HTCopyAnchor((HTAnchor *) src, new_request);
  1219.    }
  1220.    free(fd);
  1221.    free(fs);
  1222. --- 544,554 ----
  1223.        HTMethod_name(HTLink_method(link)), HTLink_result(link));
  1224.        doit = confirm(req, msg);
  1225.        free(msg);
  1226. !  } else
  1227.        HTAnchor_link((HTAnchor *) src, (HTAnchor *) dest, NULL, method);
  1228.    if (doit) {
  1229. !      req = Thread_new(lm, YES, LM_UPDATE);
  1230. !      status = HTCopyAnchor((HTAnchor *) src, req);
  1231.    }
  1232.    free(fd);
  1233.    free(fs);
  1234. ***************
  1235. *** 564,590 ****
  1236.   }
  1237.   
  1238.   /*
  1239. - **  Delete a URL
  1240. - */
  1241. - PRIVATE int DeleteURL (LineMode * lm, HTRequest * request)
  1242. - {
  1243. -     char * base = HTAnchor_address((HTAnchor*) HTMainAnchor);
  1244. -     char * url = NULL;
  1245. -     int status = HT_INTERNAL;
  1246. -     if ((url = AskUser(request, "URL to delete:", base)) != NULL) {
  1247. -  char * full = HTParse(HTStrip(url), base, PARSE_ALL);
  1248. -  HTParentAnchor * anchor=(HTParentAnchor *) HTAnchor_findAddress(full);
  1249. -  request = Thread_new(lm, YES, LM_UPDATE);
  1250. -  HTRequest_setMethod(request, METHOD_DELETE);
  1251. -  status = HTLoadAnchor((HTAnchor *) anchor, request);
  1252. -  free(full);
  1253. -     }
  1254. -     FREE(base);
  1255. -     FREE(url);
  1256. -     return status;
  1257. - }
  1258. - /*
  1259.   **  This function puts up a stream to a file in order to save a document. This
  1260.   **  is activated by '>', '>>' or '>!' from the prompt line.
  1261.   */
  1262. --- 560,565 ----
  1263. ***************
  1264. *** 735,743 ****
  1265.    break;
  1266.   
  1267.         case 'D':
  1268. !  if (CHECK_INPUT("DELETE", token)) {         /* DELETE */
  1269. !      status = DeleteURL(lm, req);
  1270. !  } else if (CHECK_INPUT("DOWN", token)) {    /* Scroll down one page  */
  1271.      down:
  1272.        if (HText_canScrollDown(HTMainText))
  1273.    HText_scrollDown(HTMainText);
  1274. --- 710,716 ----
  1275.    break;
  1276.   
  1277.         case 'D':
  1278. !  if (CHECK_INPUT("DOWN", token)) {     /* Scroll down one page  */
  1279.      down:
  1280.        if (HText_canScrollDown(HTMainText))
  1281.    HText_scrollDown(HTMainText);
  1282. ***************
  1283. *** 1211,1285 ****
  1284.   #endif
  1285.   }
  1286.   
  1287. - /* authentication_handler
  1288. - ** ----------------------
  1289. - ** This function is registered to handle access authentication,
  1290. - ** for example for HTTP
  1291. - */
  1292. - PRIVATE int authentication_handler (HTRequest * request, int status)
  1293. - {
  1294. -     Context * context = (Context *) HTRequest_context(request);
  1295. -     LineMode * lm = context->lm;
  1296. -     /* Ask the authentication module for getting credentials */
  1297. -     if (HTAA_authentication(request) && HTAA_retryWithAuth(request)) {
  1298. -  HTMethod method = HTRequest_method(request);
  1299. -  /* Make sure we do a reload from cache */
  1300. -  HTRequest_setReloadMode(request, HT_FORCE_RELOAD);
  1301. -  /* Log current request */
  1302. -  if (HTLog_isOpen()) HTLog_add(request, status);
  1303. -  /* Start request with new credentials */
  1304. -  if (HTMethod_hasEntity(method)) {    /* PUT, POST etc. */
  1305. -      HTCopyAnchor((HTAnchor *) context->source, request);
  1306. -  } else    /* GET, HEAD, DELETE etc. */
  1307. -      HTLoadAnchor((HTAnchor *) HTRequest_anchor(request), request);
  1308. -     } else {
  1309. -  TTYPrint(OUTPUT, "Access deniedn");
  1310. -  if (!HTAlert_interactive()) Cleanup(lm, -1);
  1311. -     }
  1312. -     return HT_ERROR;   /* Make sure this is the last callback in the list */
  1313. - }
  1314. - /* redirection_handler
  1315. - ** -------------------
  1316. - ** This function is registered to handle permanent and temporary
  1317. - ** redirections
  1318. - */
  1319. - PRIVATE int redirection_handler (HTRequest * request, int status)
  1320. - {
  1321. -     Context * context = (Context *) HTRequest_context(request);
  1322. -     HTMethod method = HTRequest_method(request);
  1323. -     LineMode * lm = context->lm;
  1324. -     HTAnchor * new_anchor = HTRequest_redirection(request);
  1325. -     /* Make sure we do a reload from cache */
  1326. -     HTRequest_setReloadMode(request, HT_FORCE_RELOAD);
  1327. -     /* If destination specified then bind source anchor with new destination */
  1328. -     if (HTMethod_hasEntity(method)) {
  1329. -  HTAnchor_removeAllLinks((HTAnchor *) context->source);
  1330. -  HTAnchor_link((HTAnchor *) context->source, new_anchor, NULL, method);
  1331. -     }
  1332. -     /* Log current request */
  1333. -     if (HTLog_isOpen()) HTLog_add(request, status);
  1334. -     /* Start new request */
  1335. -     if (HTRequest_retry(request)) {
  1336. -  if (HTMethod_hasEntity(method))    /* PUT, POST etc. */
  1337. -      HTCopyAnchor((HTAnchor *) context->source, request);
  1338. -  else    /* GET, HEAD, DELETE etc. */
  1339. -      HTLoadAnchor(new_anchor, request);
  1340. -     } else {
  1341. -  TTYPrint(OUTPUT, "Too many redirections detectedn");
  1342. -  if (!HTAlert_interactive()) Cleanup(lm, -1);
  1343. -     }
  1344. -     return HT_ERROR;   /* Make sure this is the last callback in the list */
  1345. - }
  1346.   /* terminate_handler
  1347.   ** -----------------
  1348.   ** This function is registered to handle the result of the request
  1349. --- 1184,1189 ----
  1350. ***************
  1351. *** 1386,1396 ****
  1352.       arc.locale=0; arc.encoding=0; arc.i_encoding=0; doinull();
  1353.   #endif
  1354.   
  1355. -     /* Create a new Line Mode object */
  1356.       lm = LineMode_new();
  1357.       /* Initiate W3C Reference Library */
  1358.       HTLibInit(APP_NAME, APP_VERSION);
  1359.   
  1360.       /* Initialize the protocol modules */
  1361.       HTAccessInit();
  1362. --- 1290,1299 ----
  1363.       arc.locale=0; arc.encoding=0; arc.i_encoding=0; doinull();
  1364.   #endif
  1365.   
  1366.       lm = LineMode_new();
  1367.       /* Initiate W3C Reference Library */
  1368.       HTLibInit(APP_NAME, APP_VERSION);
  1369. +     lm = LineMode_new();
  1370.   
  1371.       /* Initialize the protocol modules */
  1372.       HTAccessInit();
  1373. ***************
  1374. *** 1748,1758 ****
  1375.       }
  1376.   
  1377.       /* Register a call back function for the Net Manager */
  1378. !     HTNetCall_addBefore(HTLoadStart, 0);
  1379. !     HTNetCall_addAfter(authentication_handler, HT_NO_ACCESS);
  1380. !     HTNetCall_addAfter(redirection_handler, HT_PERM_REDIRECT);
  1381. !     HTNetCall_addAfter(redirection_handler, HT_TEMP_REDIRECT);
  1382. !     HTNetCall_addAfter(HTLoadTerminate, HT_ALL);
  1383.       HTNetCall_addAfter(terminate_handler, HT_ALL);
  1384.   
  1385.       /* Register our own MIME header handler for extra headers */
  1386. --- 1651,1657 ----
  1387.       }
  1388.   
  1389.       /* Register a call back function for the Net Manager */
  1390. !     HTNetInit();
  1391.       HTNetCall_addAfter(terminate_handler, HT_ALL);
  1392.   
  1393.       /* Register our own MIME header handler for extra headers */
  1394. diff -c LineMode/Repository/Implementation/Version.make:1.35.2.1 LineMode/Repository/Implementation/Version.make:1.35
  1395. *** LineMode/Repository/Implementation/Version.make:1.35.2.1 Tue Jan 23 16:32:02 1996
  1396. --- LineMode/Repository/Implementation/Version.make Tue Jan 23 16:32:02 1996
  1397. ***************
  1398. *** 1 ****
  1399. ! VL = 4.0C
  1400. --- 1 ----
  1401. ! VL = 4.0B
  1402. diff -c ComLine/Repository/Implementation/HTLine.c:1.8.2.1 ComLine/Repository/Implementation/HTLine.c:1.8
  1403. *** ComLine/Repository/Implementation/HTLine.c:1.8.2.1 Tue Jan 23 16:32:04 1996
  1404. --- ComLine/Repository/Implementation/HTLine.c Tue Jan 23 16:32:05 1996
  1405. ***************
  1406. *** 65,71 ****
  1407.       HTRequest * request;
  1408.       HTParentAnchor * anchor;
  1409.       HTParentAnchor * dest;  /* Destination for PUT etc. */
  1410. -     HTMethod method;       /* What method are we envoking */
  1411.       struct timeval * tv; /* Timeout on socket */
  1412.       char * cwd;   /* Current dir URL */
  1413.       char * rules;
  1414. --- 65,70 ----
  1415. ***************
  1416. *** 155,226 ****
  1417.       TTYPrint(OUTPUT,"Please send feedback to <libwww@w3.org>n");
  1418.   }
  1419.   
  1420. - /* authentication_handler
  1421. - ** ----------------------
  1422. - ** This function is registered to handle access authentication,
  1423. - ** for example for HTTP
  1424. - */
  1425. - PRIVATE int authentication_handler (HTRequest * request, int status)
  1426. - {
  1427. -     ComLine * cl = (ComLine *) HTRequest_context(request);
  1428. -     /* Ask the authentication module for getting credentials */
  1429. -     if (HTAA_authentication(request) && HTAA_retryWithAuth(request)) {
  1430. -  /* Make sure we do a reload from cache */
  1431. -  HTRequest_setReloadMode(request, HT_FORCE_RELOAD);
  1432. -  /* Log current request */
  1433. -  if (HTLog_isOpen()) HTLog_add(request, status);
  1434. -  /* Start request with new credentials */
  1435. -  if (cl->dest)    /* PUT, POST etc. */
  1436. -      HTCopyAnchor((HTAnchor *) cl->anchor, cl->request);
  1437. -  else    /* GET, HEAD, DELETE etc. */
  1438. -      HTLoadAnchor((HTAnchor *) cl->anchor, cl->request);
  1439. -     } else {
  1440. -  TTYPrint(OUTPUT, "Access deniedn");
  1441. -  Cleanup(cl, -1);
  1442. -     }
  1443. -     return HT_ERROR;   /* Make sure this is the last callback in the list */
  1444. - }
  1445. - /* redirection_handler
  1446. - ** -------------------
  1447. - ** This function is registered to handle permanent and temporary
  1448. - ** redirections
  1449. - */
  1450. - PRIVATE int redirection_handler (HTRequest * request, int status)
  1451. - {
  1452. -     BOOL result = YES;
  1453. -     ComLine * cl = (ComLine *) HTRequest_context(request);
  1454. -     HTAnchor * new_anchor = HTRequest_redirection(request);
  1455. -     /* Make sure we do a reload from cache */
  1456. -     HTRequest_setReloadMode(request, HT_FORCE_RELOAD);
  1457. -     /* If destination specified then bind together anchors */
  1458. -     if (cl->dest) {
  1459. -  HTAnchor_removeAllLinks((HTAnchor *) cl->anchor);
  1460. -  HTAnchor_link((HTAnchor *) cl->anchor, new_anchor, NULL, cl->method);
  1461. -     }
  1462. -     /* Log current request */
  1463. -     if (HTLog_isOpen()) HTLog_add(request, status);
  1464. -     /* Start new request */
  1465. -     if (HTRequest_retry(request)) {
  1466. -  if (cl->dest)    /* PUT, POST etc. */
  1467. -      result = HTCopyAnchor((HTAnchor *) cl->anchor, cl->request);
  1468. -  else    /* GET, HEAD, DELETE etc. */
  1469. -      result = HTLoadAnchor(new_anchor, cl->request);
  1470. -     } else {
  1471. -  TTYPrint(OUTPUT, "Too many redirections detectedn");
  1472. -  Cleanup(cl, -1);
  1473. -     }
  1474. -     return HT_ERROR;   /* Make sure this is the last callback in the list */
  1475. - }
  1476.   /* terminate_handler
  1477.   ** -----------------
  1478.   ** This function is registered to handle the result of the request
  1479. --- 154,159 ----
  1480. ***************
  1481. *** 234,247 ****
  1482.    TTYPrint(OUTPUT, "Content Length found to be %ldn",
  1483.     HTAnchor_length(cl->anchor));
  1484.        }
  1485.    }
  1486. -     } else {
  1487. -  HTAlertCallback *cbf = HTAlert_find(HT_A_MESSAGE);
  1488. -  if (cbf) (*cbf)(request, HT_A_MESSAGE, HT_MSG_NULL, NULL,
  1489. -  HTRequest_error(request), NULL);
  1490.       }
  1491.       if (HTLog_isOpen()) HTLog_add(request, status);
  1492. -     Cleanup(cl, status == HT_LOADED ? 0 : -1);
  1493.       return HT_OK;
  1494.   }
  1495.   
  1496. --- 167,176 ----
  1497.    TTYPrint(OUTPUT, "Content Length found to be %ldn",
  1498.     HTAnchor_length(cl->anchor));
  1499.        }
  1500. +      Cleanup(cl, status == HT_LOADED ? 0 : -1);
  1501.    }
  1502.       }
  1503.       if (HTLog_isOpen()) HTLog_add(request, status);
  1504.       return HT_OK;
  1505.   }
  1506.   
  1507. ***************
  1508. *** 300,306 ****
  1509.   
  1510.       /* Initiate W3C Reference Library */
  1511.       HTLibInit(APP_NAME, APP_VERSION);
  1512. -     HTAlert_setInteractive(YES);
  1513.   
  1514.       /* Initialize the protocol modules */
  1515.       HTProtocol_add("http", NO, HTLoadHTTP, NULL);
  1516. --- 229,234 ----
  1517. ***************
  1518. *** 445,467 ****
  1519.        } else if (!strcasecomp(argv[arg], "-delete")) {
  1520.    HTRequest_setMethod(cl->request, METHOD_DELETE);
  1521.   
  1522. -      /*
  1523. -      ** Note that we for PUT and POST still use the GET method as we
  1524. -      ** store methods in a POST web in the link relationship between
  1525. -      ** anchors. This allows us to have multiple destinations each
  1526. -      ** with their own method as described in the POST web in the online
  1527. -      ** documentation of the Library
  1528. -      */
  1529.        /* POST Method */
  1530.        } else if (!strcasecomp(argv[arg], "-post")) {
  1531. !  cl->method = METHOD_POST;
  1532. !  HTRequest_setMethod(cl->request, METHOD_GET);
  1533.   
  1534.        /* PUT Method */
  1535.        } else if (!strcasecomp(argv[arg], "-put")) {
  1536. !  cl->method = METHOD_PUT;
  1537. !  HTRequest_setMethod(cl->request, METHOD_GET);
  1538.   
  1539.        } else {
  1540.    if (SHOW_MSG) TTYPrint(TDEST,"Bad Argument (%s)n", argv[arg]);
  1541. --- 373,385 ----
  1542.        } else if (!strcasecomp(argv[arg], "-delete")) {
  1543.    HTRequest_setMethod(cl->request, METHOD_DELETE);
  1544.   
  1545.        /* POST Method */
  1546.        } else if (!strcasecomp(argv[arg], "-post")) {
  1547. !  HTRequest_setMethod(cl->request, METHOD_POST);
  1548.   
  1549.        /* PUT Method */
  1550.        } else if (!strcasecomp(argv[arg], "-put")) {
  1551. !  HTRequest_setMethod(cl->request, METHOD_PUT);
  1552.   
  1553.        } else {
  1554.    if (SHOW_MSG) TTYPrint(TDEST,"Bad Argument (%s)n", argv[arg]);
  1555. ***************
  1556. *** 493,501 ****
  1557.    Cleanup(cl, -1);
  1558.       }
  1559.   
  1560. !     /* If destination specified then bind together anchors */
  1561. !     if (cl->dest) HTAnchor_link((HTAnchor*)cl->anchor,
  1562. !  (HTAnchor*)cl->dest, NULL, cl->method);
  1563.   
  1564.       /* Output file specified? */
  1565.       if (cl->outputfile) {
  1566. --- 411,421 ----
  1567.    Cleanup(cl, -1);
  1568.       }
  1569.   
  1570. !     /* Destination specified? */
  1571. !     if (cl->dest) {
  1572. !  HTMethod method = HTRequest_method(cl->request);
  1573. !  HTAnchor_link((HTAnchor*)cl->anchor, (HTAnchor*)cl->dest, NULL,method);
  1574. !     }
  1575.   
  1576.       /* Output file specified? */
  1577.       if (cl->outputfile) {
  1578. ***************
  1579. *** 530,545 ****
  1580.   
  1581.       /* Register our User Prompts etc in the Alert Manager */
  1582.       if (HTAlert_interactive()) {
  1583. -  HTAlert_add(HTProgress, HT_A_PROGRESS);
  1584.    HTAlert_add(HTError_print, HT_A_MESSAGE);
  1585.    HTAlert_add(HTPromptUsernameAndPassword, HT_A_USER_PW);
  1586.       }
  1587.   
  1588.       /* Register a call back function for the Net Manager */
  1589. -     HTNetCall_addAfter(authentication_handler, HT_NO_ACCESS);
  1590. -     HTNetCall_addAfter(redirection_handler, HT_PERM_REDIRECT);
  1591. -     HTNetCall_addAfter(redirection_handler, HT_TEMP_REDIRECT);
  1592.       HTNetCall_addAfter(terminate_handler, HT_ALL);
  1593.       
  1594.       /* Register our own MIME header handler for extra headers */
  1595. --- 450,460 ----
  1596. ***************
  1597. *** 569,580 ****
  1598.       if (cl->dest)    /* PUT, POST etc. */
  1599.    status = HTCopyAnchor((HTAnchor *) cl->anchor, cl->request);
  1600.       else if (keywords)    /* Search */
  1601. -  /*
  1602. -  ** Note that a search also can be done by creating a URL with the '?'
  1603. -  ** and the set of keywords embedded and then use HTLoadAnchor directly
  1604. -  */
  1605.    status = HTSearch(HTChunk_data(keywords), cl->anchor, cl->request);
  1606. !     else    /* GET, HEAD, DELETE etc. */
  1607.    status = HTLoadAnchor((HTAnchor *) cl->anchor, cl->request);
  1608.   
  1609.       if (keywords) HTChunk_delete(keywords);
  1610. --- 484,491 ----
  1611.       if (cl->dest)    /* PUT, POST etc. */
  1612.    status = HTCopyAnchor((HTAnchor *) cl->anchor, cl->request);
  1613.       else if (keywords)    /* Search */
  1614.    status = HTSearch(HTChunk_data(keywords), cl->anchor, cl->request);
  1615. !     else    /* GET, HEAD etc. */
  1616.    status = HTLoadAnchor((HTAnchor *) cl->anchor, cl->request);
  1617.   
  1618.       if (keywords) HTChunk_delete(keywords);
  1619. diff -c ComLine/Repository/Implementation/Version.make:1.8.2.1 ComLine/Repository/Implementation/Version.make:1.8
  1620. *** ComLine/Repository/Implementation/Version.make:1.8.2.1 Tue Jan 23 16:32:06 1996
  1621. --- ComLine/Repository/Implementation/Version.make Tue Jan 23 16:32:06 1996
  1622. ***************
  1623. *** 1 ****
  1624. ! VT = 4.0C
  1625. --- 1 ----
  1626. ! VT = 4.0B
  1627. diff -c ComLine/Repository/User/CommandLine.html:1.3 ComLine/Repository/User/CommandLine.html:1.4
  1628. *** ComLine/Repository/User/CommandLine.html:1.3 Tue Jan 23 16:32:09 1996
  1629. --- ComLine/Repository/User/CommandLine.html Tue Jan 23 16:32:09 1996
  1630. ***************
  1631. *** 1,7 ****
  1632.   <HTML>
  1633.   <HEAD>
  1634.   <TITLE>Command Line Syntax for the W3C Command Line Tool</TITLE>
  1635. ! <!-- Changed by: Henrik Frystyk Nielsen, 29-Nov-1995 -->
  1636.   <NEXTID N="z29">
  1637.   </HEAD>
  1638.   
  1639. --- 1,7 ----
  1640.   <HTML>
  1641.   <HEAD>
  1642.   <TITLE>Command Line Syntax for the W3C Command Line Tool</TITLE>
  1643. ! <!-- Changed by: Henrik Frystyk Nielsen, 19-Jan-1996 -->
  1644.   <NEXTID N="z29">
  1645.   </HEAD>
  1646.   
  1647. ***************
  1648. *** 119,130 ****
  1649.   <DT><B>-put</B>
  1650.   <DD>Uploads a document from either the local file system or a remote HTTP server to a remote HTTP
  1651.   server (destination) using <B>PUT</B> method. You must indicate the destination using the
  1652. ! <CODE>-dest</CODE> command line option.
  1653.   
  1654.   <DT><B>-post</B> 
  1655.   <DD>Uploads a document from either the local file system or a remote HTTP server to a remote HTTP
  1656.   server (destination) using <B>POST</B> method. You must indicate the destination using the
  1657. ! <CODE>-dest</CODE> command line option.
  1658.   
  1659.   <DT><B>-link</B> 
  1660.   <DD>Being implemented
  1661. --- 119,130 ----
  1662.   <DT><B>-put</B>
  1663.   <DD>Uploads a document from either the local file system or a remote HTTP server to a remote HTTP
  1664.   server (destination) using <B>PUT</B> method. You must indicate the destination using the
  1665. ! <B>-dest</B> command line option.
  1666.   
  1667.   <DT><B>-post</B> 
  1668.   <DD>Uploads a document from either the local file system or a remote HTTP server to a remote HTTP
  1669.   server (destination) using <B>POST</B> method. You must indicate the destination using the
  1670. ! <B>-dest</B> command line option.
  1671.   
  1672.   <DT><B>-link</B> 
  1673.   <DD>Being implemented
  1674. diff -c Robot/Repository/Implementation/HTRobot.c:1.6.2.2 Robot/Repository/Implementation/HTRobot.c:1.6
  1675. *** Robot/Repository/Implementation/HTRobot.c:1.6.2.2 Tue Jan 23 16:32:12 1996
  1676. --- Robot/Repository/Implementation/HTRobot.c Tue Jan 23 16:32:13 1996
  1677. ***************
  1678. *** 32,42 ****
  1679.   #define DEFAULT_OUTPUT_FILE "robot.out"
  1680.   #define DEFAULT_RULE_FILE "robot.conf"
  1681.   #define DEFAULT_LOG_FILE        "robot.log"
  1682. - #define DEFAULT_DEPTH 0
  1683.   
  1684.   #define SHOW_MSG (WWWTRACE || HTAlert_interactive())
  1685.   
  1686. ! #define DEFAULT_TIMEOUT 10        /* timeout in seconds */
  1687.   
  1688.   #if defined(__svr4__)
  1689.   #define CATCH_SIG
  1690. --- 32,41 ----
  1691.   #define DEFAULT_OUTPUT_FILE "robot.out"
  1692.   #define DEFAULT_RULE_FILE "robot.conf"
  1693.   #define DEFAULT_LOG_FILE        "robot.log"
  1694.   
  1695.   #define SHOW_MSG (WWWTRACE || HTAlert_interactive())
  1696.   
  1697. ! #define DEFAULT_TIMEOUT 60        /* timeout in seconds */
  1698.   
  1699.   #if defined(__svr4__)
  1700.   #define CATCH_SIG
  1701. ***************
  1702. *** 50,56 ****
  1703.   
  1704.   typedef struct _Robot {
  1705.       HTRequest * request;
  1706. -     HTRequest * timeout;   /* Until we get a server eventloop */
  1707.       HTParentAnchor * anchor;
  1708.       int depth;      /* How deep is our tree */
  1709.       HTList * hyperdoc;      /* List of our HyperDoc Objects */
  1710. --- 49,54 ----
  1711. ***************
  1712. *** 116,121 ****
  1713. --- 114,123 ----
  1714.       /* Add this HyperDoc object to our list */
  1715.       if (!mr->hyperdoc) mr->hyperdoc = HTList_new();
  1716.       HTList_addObject(mr->hyperdoc, (void *) hd);
  1717. +     if (SHOW_MSG)
  1718. +  TTYPrint(TDEST, "HyperDoc.... %p bound to anchor %p with depth %dn",
  1719. +   hd, anchor, depth);
  1720.       return hd;
  1721.   }
  1722.   
  1723. ***************
  1724. *** 146,155 ****
  1725.       me->cwd = HTFindRelatedName();
  1726.       me->output = OUTPUT;
  1727.   
  1728. -     /* We keep an extra timeout request object for the timeout_handler */
  1729. -     me->timeout = HTRequest_new();
  1730. -     HTRequest_setContext (me->timeout, me);
  1731.       /* Bind the Robot object together with the Request Object */
  1732.       me->request = HTRequest_new();
  1733.       HTRequest_setContext (me->request, me);
  1734. --- 148,153 ----
  1735. ***************
  1736. *** 270,288 ****
  1737.   /* timeout_handler
  1738.   ** ---------------
  1739.   ** This function is registered to handle timeout in select eventloop
  1740. - **
  1741. - ** BUG: This doesn't work as we don't get the right request object
  1742. - ** back from the event loop
  1743.   */
  1744.   PRIVATE int timeout_handler (HTRequest * request)
  1745.   {
  1746.       Robot * mr = (Robot *) HTRequest_context(request);
  1747.       if (SHOW_MSG) TTYPrint(TDEST, "Robot....... Request timeout...n");
  1748. - #if 0
  1749.       HTRequest_kill(request);
  1750.       Thread_delete(mr, request);
  1751. ! #endif
  1752. !     Cleanup(mr, -1);
  1753.       return HT_OK;
  1754.   }
  1755.   
  1756. --- 268,281 ----
  1757.   /* timeout_handler
  1758.   ** ---------------
  1759.   ** This function is registered to handle timeout in select eventloop
  1760.   */
  1761.   PRIVATE int timeout_handler (HTRequest * request)
  1762.   {
  1763.       Robot * mr = (Robot *) HTRequest_context(request);
  1764.       if (SHOW_MSG) TTYPrint(TDEST, "Robot....... Request timeout...n");
  1765.       HTRequest_kill(request);
  1766.       Thread_delete(mr, request);
  1767. !     if (HTNet_isEmpty()) Cleanup(mr, -1);
  1768.       return HT_OK;
  1769.   }
  1770.   
  1771. ***************
  1772. *** 317,327 ****
  1773.    Robot * mr = (Robot *) HTRequest_context(text->request);
  1774.    HTAnchor * dest = HTAnchor_followMainLink((HTAnchor *) anchor);
  1775.    HTParentAnchor * dest_parent = HTAnchor_parent(dest);
  1776. -  char * uri = HTAnchor_address((HTAnchor *) dest_parent);
  1777.    HyperDoc * hd = HTAnchor_document(dest_parent);
  1778.   
  1779. -  if (SHOW_MSG) TTYPrint(TDEST, "Robot....... Found `%s' - ", uri ? uri : "NULL");
  1780.    /* Test whether we already have a hyperdoc for this document */
  1781.    if (mr->flags & MR_LINK && dest_parent && !hd) {
  1782.        HTParentAnchor * parent = HTRequest_parent(text->request);
  1783. --- 310,317 ----
  1784. ***************
  1785. *** 329,351 ****
  1786.        int depth = last ? last->depth+1 : 0;
  1787.        HTRequest * newreq = Thread_new(mr, METHOD_GET);
  1788.        HyperDoc_new(mr, dest_parent, depth);
  1789. !      HTRequest_setParent(newreq, HTRequest_anchor(text->request));
  1790. !      if (depth >= mr->depth) {
  1791. !  if (SHOW_MSG)
  1792. !      TTYPrint(TDEST, "loading at depth %d using HEADn", depth);
  1793. !  HTRequest_setMethod(newreq, METHOD_HEAD);
  1794. !  HTRequest_setOutputFormat(newreq, WWW_MIME);
  1795. !      } else {
  1796. !  if (SHOW_MSG) TTYPrint(TDEST, "loading at depth %dn", depth);
  1797.        }
  1798.        if (HTLoadAnchor((HTAnchor *) dest_parent, newreq) != YES) {
  1799. !  if (SHOW_MSG) TTYPrint(TDEST, "not tested!n");
  1800.    Thread_delete(mr, newreq);
  1801.        }
  1802. -  } else {
  1803. -      if (SHOW_MSG) TTYPrint(TDEST, "duplicaten");
  1804.    }
  1805. -  FREE(uri);
  1806.       }
  1807.   }
  1808.   
  1809. --- 319,334 ----
  1810.        int depth = last ? last->depth+1 : 0;
  1811.        HTRequest * newreq = Thread_new(mr, METHOD_GET);
  1812.        HyperDoc_new(mr, dest_parent, depth);
  1813. !      if (SHOW_MSG) {
  1814. !  char * uri = HTAnchor_address((HTAnchor *) dest_parent);
  1815. !  TTYPrint(TDEST, "Robot....... Loading `%s'n", uri);
  1816. !  free(uri);
  1817.        }
  1818.        if (HTLoadAnchor((HTAnchor *) dest_parent, newreq) != YES) {
  1819. !  if (SHOW_MSG) TTYPrint(TDEST, "Robot...... URI Not tested!n");
  1820.    Thread_delete(mr, newreq);
  1821.        }
  1822.    }
  1823.       }
  1824.   }
  1825.   
  1826. ***************
  1827. *** 479,486 ****
  1828.        /* load anchors */
  1829.        } else if (!strcmp(argv[arg], "-link")) {
  1830.    mr->flags |= MR_LINK;
  1831. -  mr->depth = (arg+1 < argc && *argv[arg+1] != '-') ?
  1832. -      atoi(argv[++arg]) : DEFAULT_DEPTH;
  1833.   
  1834.        /* preemtive or non-preemtive access */
  1835.        } else if (!strcmp(argv[arg], "-single")) {
  1836. --- 462,467 ----
  1837. ***************
  1838. *** 523,529 ****
  1839.            if (!keycnt) {
  1840.    char * ref = HTParse(argv[arg], mr->cwd, PARSE_ALL);
  1841.    mr->anchor = (HTParentAnchor *) HTAnchor_findAddress(ref);
  1842. -  HyperDoc_new(mr, mr->anchor, 0);
  1843.    keycnt = 1;
  1844.    FREE(ref);
  1845.        } else {    /* Check for successive keyword arguments */
  1846. --- 504,509 ----
  1847. ***************
  1848. *** 591,597 ****
  1849.       HTNetCall_addAfter(terminate_handler, HT_ALL);
  1850.       
  1851.       /* Set timeout on sockets */
  1852. !     HTEvent_registerTimeout(mr->tv, mr->timeout, timeout_handler, NO);
  1853.   
  1854.       /* Start the request */
  1855.       if (keywords)    /* Search */
  1856. --- 571,577 ----
  1857.       HTNetCall_addAfter(terminate_handler, HT_ALL);
  1858.       
  1859.       /* Set timeout on sockets */
  1860. !     HTEvent_registerTimeout(mr->tv, mr->request, timeout_handler, NO);
  1861.   
  1862.       /* Start the request */
  1863.       if (keywords)    /* Search */
  1864. diff -c Robot/Repository/Implementation/Version.make:1.5.2.1 Robot/Repository/Implementation/Version.make:1.5
  1865. *** Robot/Repository/Implementation/Version.make:1.5.2.1 Tue Jan 23 16:32:14 1996
  1866. --- Robot/Repository/Implementation/Version.make Tue Jan 23 16:32:15 1996
  1867. ***************
  1868. *** 1 ****
  1869. ! VR = 4.0C
  1870. --- 1 ----
  1871. ! VR = 4.0B
  1872. diff -c Robot/Repository/User/CommandLine.html:1.2 Robot/Repository/User/CommandLine.html:1.3
  1873. *** Robot/Repository/User/CommandLine.html:1.2 Tue Jan 23 16:32:17 1996
  1874. --- Robot/Repository/User/CommandLine.html Tue Jan 23 16:32:17 1996
  1875. ***************
  1876. *** 1,7 ****
  1877.   <HTML>
  1878.   <HEAD>
  1879.   <TITLE>Command Line Syntax for the W3C Mini Robot</TITLE>
  1880. ! <!-- Changed by: Henrik Frystyk Nielsen,  6-Dec-1995 -->
  1881.   <NEXTID N="z29">
  1882.   </HEAD>
  1883.   
  1884. --- 1,7 ----
  1885.   <HTML>
  1886.   <HEAD>
  1887.   <TITLE>Command Line Syntax for the W3C Mini Robot</TITLE>
  1888. ! <!-- Changed by: Henrik Frystyk Nielsen, 17-Jan-1996 -->
  1889.   <NEXTID N="z29">
  1890.   </HEAD>
  1891.   
  1892. ***************
  1893. *** 71,78 ****
  1894.   <DD>Specifies a log file with a list of visited documents. The default
  1895.   value is "www-log"
  1896.   
  1897. ! <DT><B>-link</B>
  1898. ! <DD>Fetch all links from this document
  1899.   
  1900.   <DT><B>-n</B>
  1901.   <DD>Non-interactive mode. Outputs the formatted document to the
  1902. --- 71,82 ----
  1903.   <DD>Specifies a log file with a list of visited documents. The default
  1904.   value is "www-log"
  1905.   
  1906. ! <DT><B>-link</B> [ n ]
  1907. ! <DD>Fetch all links from this document. By indicating an integer "n" as the parameter you can
  1908. ! specify the depth of which the search should go. The default value is 0 which means that only the
  1909. ! start page is searched. Level 1 insicates that the start page <B>and</B> all pages directly linked
  1910. ! from the start page are searched.
  1911.   
  1912.   <DT><B>-n</B>
  1913.   <DD>Non-interactive mode. Outputs the formatted document to the
  1914. diff -c Robot/Repository/User/Patch/Overview.html:1.1 Robot/Repository/User/Patch/Overview.html:1.2
  1915. *** Robot/Repository/User/Patch/Overview.html:1.1 Tue Jan 23 16:32:19 1996
  1916. --- Robot/Repository/User/Patch/Overview.html Tue Jan 23 16:32:19 1996
  1917. ***************
  1918. *** 1,7 ****
  1919.   <HTML>
  1920.   <HEAD>
  1921.   <TITLE>Known Bugs in W3C Mini Robot</TITLE>
  1922. ! <!-- Changed by: Henrik Frystyk Nielsen,  6-Dec-1995 -->
  1923.   </HEAD>
  1924.   <BODY>
  1925.   
  1926. --- 1,7 ----
  1927.   <HTML>
  1928.   <HEAD>
  1929.   <TITLE>Known Bugs in W3C Mini Robot</TITLE>
  1930. ! <!-- Changed by: Henrik Frystyk Nielsen, 17-Jan-1996 -->
  1931.   </HEAD>
  1932.   <BODY>
  1933.   
  1934. ***************
  1935. *** 42,50 ****
  1936.   
  1937.   <HR>
  1938.   
  1939. ! <UL>
  1940. ! <LI> 
  1941. ! </UL>
  1942.   
  1943.   <P>
  1944.   <HR>
  1945. --- 42,55 ----
  1946.   
  1947.   <HR>
  1948.   
  1949. ! <H2>Robot 4.0</H2>
  1950. ! <DL>
  1951. ! <DT><A HREF="robot_4.0_1.fix">Improvement patch</A>
  1952. ! <DD>Fixes two problems in the anchor traversal and adds <B>depth</B> as a valid parameter so that
  1953. ! you can specify how many hops to go from the start page.
  1954. ! </DL>
  1955.   
  1956.   <P>
  1957.   <HR>
  1958. diff -c MiniServ/Repository/Implementation/Version.make:1.7.2.1 MiniServ/Repository/Implementation/Version.make:1.7
  1959. *** MiniServ/Repository/Implementation/Version.make:1.7.2.1 Tue Jan 23 16:32:22 1996
  1960. --- MiniServ/Repository/Implementation/Version.make Tue Jan 23 16:32:22 1996
  1961. ***************
  1962. *** 1 ****
  1963. ! VS = 4.0C
  1964. --- 1 ----
  1965. ! VS = 4.0B
  1966. diff -c MiniServ/Repository/User/CommandLine.html:1.2 MiniServ/Repository/User/CommandLine.html:1.3
  1967. *** MiniServ/Repository/User/CommandLine.html:1.2 Tue Jan 23 16:32:24 1996
  1968. --- MiniServ/Repository/User/CommandLine.html Tue Jan 23 16:32:25 1996
  1969. ***************
  1970. *** 129,136 ****
  1971.   <DT><B>-backlog</B> &lt;n&gt;
  1972.   <DD>Number of connections pending in the <CODE>listen</CODE> queue
  1973.   
  1974. ! <DT><B>-preemtive</B> 
  1975. ! <DD>Preemtive (blocking) sockets
  1976.   
  1977.   </DL>
  1978.   
  1979. --- 129,136 ----
  1980.   <DT><B>-backlog</B> &lt;n&gt;
  1981.   <DD>Number of connections pending in the <CODE>listen</CODE> queue
  1982.   
  1983. ! <DT><B>-preemptive</B> 
  1984. ! <DD>Preemptive (blocking) sockets
  1985.   
  1986.   </DL>
  1987.