--- ./WWW/Library/Implementation/HTParse.h Wed Oct 25 12:35:28 2000 +++ ../lynx2-8-4/./WWW/Library/Implementation/HTParse.h Thu Feb 13 18:05:32 2003 @@ -113,26 +113,39 @@ ** ------------------------------------- ** ** This function takes a pointer to a string in which -** some characters may be unacceptable unescaped. +** some characters may be unacceptable are unescaped. ** It returns a string which has these characters ** represented by a '%' character followed by two hex digits. ** -** Unlike HTUnEscape(), this routine returns a malloced string. +** Unlike HTUnEscape(), this routine returns a malloc'd string. */ extern char * HTEscape PARAMS(( CONST char * str, unsigned char mask)); +/* Escape unsafe characters using % HTEscapeUnsafe() +** -------------------------------- +** +** This function takes a pointer to a string in which +** some characters may be that may be unsafe are unescaped. +** It returns a string which has these characters +** represented by a '%' character followed by two hex digits. +** +** Unlike HTUnEscape(), this routine returns a malloc'd string. +*/ +extern char * HTEscapeUnsafe PARAMS(( + CONST char * str)); + /* Escape undesirable characters using % but space to +. HTEscapeSP() ** ----------------------------------------------------- ** ** This function takes a pointer to a string in which -** some characters may be unacceptable unescaped. +** some characters may be unacceptable are unescaped. ** It returns a string which has these characters ** represented by a '%' character followed by two hex digits, ** except that spaces are converted to '+' instead of %2B. ** -** Unlike HTUnEscape(), this routine returns a malloced string. +** Unlike HTUnEscape(), this routine returns a malloc'd string. */ extern char * HTEscapeSP PARAMS(( CONST char * str, --- ./WWW/Library/Implementation/HTParse.c Sun Apr 1 20:51:46 2001 +++ ../lynx2-8-4/./WWW/Library/Implementation/HTParse.c Thu Feb 13 18:05:32 2003 @@ -696,8 +696,8 @@ return result; } -/* Escape undesirable characters using % HTEscape() -** ------------------------------------- +/* Escape undesirable characters using % HTEscape() +** ------------------------------------- ** ** This function takes a pointer to a string in which ** some characters may be unacceptable unescaped. @@ -710,7 +710,7 @@ /* Bit 0 xalpha -- see HTFile.h ** Bit 1 xpalpha -- as xalpha but with plus. -** Bit 3 ... path -- as xpalphas but with / +** Bit 2 ... path -- as xpalphas but with / */ /* 0 1 2 3 4 5 6 7 8 9 A B C D E F */ { 0,0,0,0,0,0,0,0,0,0,7,6,0,7,7,4, /* 2x !"#$%&'()*+,-./ */ @@ -740,13 +740,51 @@ for (q = result, p = str; *p; p++) { unsigned char a = TOASCII(*p); if (!ACCEPTABLE(a)) { - *q++ = HEX_ESCAPE; /* Means hex commming */ + *q++ = HEX_ESCAPE; /* Means hex coming */ *q++ = hex[a >> 4]; *q++ = hex[a & 15]; } else *q++ = *p; } - *q++ = '\0'; /* Terminate */ + *q++ = '\0'; /* Terminate */ + return result; +} + +/* Escape unsafe characters using % HTEscapeUnsafe() +** -------------------------------- +** +** This function takes a pointer to a string in which +** some characters may be that may be unsafe are unescaped. +** It returns a string which has these characters +** represented by a '%' character followed by two hex digits. +** +** Unlike HTUnEscape(), this routine returns a malloc'd string. +*/ +#define UNSAFE(ch) (((ch) <= 32) || ((ch) >= 127)) + +PUBLIC char *HTEscapeUnsafe ARGS1( + CONST char *, str) +{ + CONST char * p; + char * q; + char * result; + int unacceptable = 0; + for (p = str; *p; p++) + if (UNSAFE(UCH(TOASCII(*p)))) + unacceptable++; + result = typecallocn(char, p-str + unacceptable + unacceptable + 1); + if (result == NULL) + outofmem(__FILE__, "HTEscapeUnsafe"); + for (q = result, p = str; *p; p++) { + unsigned char a = TOASCII(*p); + if (UNSAFE(a)) { + *q++ = HEX_ESCAPE; /* Means hex coming */ + *q++ = hex[a >> 4]; + *q++ = hex[a & 15]; + } + else *q++ = *p; + } + *q++ = '\0'; /* Terminate */ return result; } --- ./src/LYMainLoop.c Sat Jul 7 21:30:13 2001 +++ ../lynx2-8-4/./src/LYMainLoop.c Thu Feb 13 18:05:32 2003 @@ -689,9 +689,7 @@ /* * Get rid of leading spaces (and any other spaces). */ - if (!LYTrimStartfile(user_input_buffer)) { - LYRemoveBlanks(user_input_buffer); - } + LYTrimAllStartfile(user_input_buffer); if (*user_input_buffer == '\0' && !(recall && (ch == UPARROW || ch == DNARROW))) { LYstrncpy(user_input_buffer, *old_user_input, MAX_LINE - 1); @@ -2394,9 +2392,7 @@ MAX_LINE, RECALL_URL)) >= 0) && user_input_buffer[0] != '\0' && strcmp(user_input_buffer, curdoc.address)) { - if (!LYTrimStartfile(user_input_buffer)) { - LYRemoveBlanks(user_input_buffer); - } + LYTrimAllStartfile(user_input_buffer); if (user_input_buffer[0] != '\0') { return 2; } @@ -2657,9 +2653,7 @@ ((links[curdoc.link].type == WWW_FORM_LINK_TYPE) ? links[curdoc.link].form->submit_action : links[curdoc.link].lname))) { - if (!LYTrimStartfile(user_input_buffer)) { - LYRemoveBlanks(user_input_buffer); - } + LYTrimAllStartfile(user_input_buffer); if (user_input_buffer[0] != '\0') { return 2; } @@ -6143,7 +6137,7 @@ * WINDOW structures are already filled based on the old size. * So we notify the ncurses library directly here. - kw */ -#if defined(NCURSES) && defined(HAVE_RESIZETERM) +#if defined(NCURSES) && defined(HAVE_RESIZETERM) && defined(HAVE_WRESIZE) resizeterm(LYlines, LYcols); wresize(LYwin, LYlines, LYcols); #else --- ./src/LYMain.c Sat Jul 7 21:30:13 2001 +++ ../lynx2-8-4/./src/LYMain.c Sun Feb 16 20:36:32 2003 @@ -47,7 +47,9 @@ #endif #ifdef LOCALE +#ifdef sun #undef gettext /* Solaris locale.h prototypes gettext() */ +#endif #include #ifndef HAVE_GETTEXT #define gettext(s) s @@ -442,7 +444,13 @@ #endif /* EXP_PERSISTENT_COOKIES */ #ifdef EXP_NESTED_TABLES -PUBLIC BOOLEAN nested_tables = TRUE; +PUBLIC BOOLEAN nested_tables = +#if defined(USE_COLOR_STYLE) + TRUE +#else + FALSE /* see 2001-08-15 */ +#endif + ; #endif PUBLIC BOOLEAN LYShowTransferRate = TRUE; @@ -1041,7 +1049,7 @@ StrAllocCopy(helpfile, HELPFILE); StrAllocCopy(startfile, STARTFILE); - LYTrimStartfile(startfile); + LYEscapeStartfile(&startfile); StrAllocCopy(indexfile, DEFAULT_INDEX_FILE); StrAllocCopy(global_type_map, GLOBAL_MAILCAP); StrAllocCopy(personal_type_map, PERSONAL_MAILCAP); @@ -1503,7 +1511,7 @@ */ if ((cp = getenv("WWW_HOME")) != NULL) { StrAllocCopy(startfile, cp); - LYTrimStartfile(startfile); + LYEscapeStartfile(&startfile); } /* @@ -2646,7 +2654,7 @@ { if (next_arg != 0) { StrAllocCopy(homepage, next_arg); - LYTrimStartfile(homepage); + LYEscapeStartfile(&homepage); } return 0; } @@ -3946,7 +3954,7 @@ had_nonoption = TRUE; #endif StrAllocCopy(startfile, arg_name); - LYTrimStartfile(startfile); + LYEscapeStartfile(&startfile); #ifdef _WINDOWS /* 1998/01/14 (Wed) 20:11:17 */ HTUnEscape(startfile); { --- ./src/LYStrings.c Sun Jun 10 21:04:20 2001 +++ ../lynx2-8-4/./src/LYStrings.c Thu Feb 13 18:05:32 2003 @@ -703,6 +703,36 @@ #define GetChar() wgetch(my_subwindow ? my_subwindow : LYwin) #endif +#if !defined(GetChar) && defined(PDCURSES) +/* PDCurses sends back key-modifiers that we don't use, but would waste time + * upon, e.g., repainting the status line + */ +PRIVATE int myGetChar NOARGS +{ + int c; + BOOL done = FALSE; + + do { + switch (c = wgetch(LYwin)) + { + case KEY_SHIFT_L : + case KEY_SHIFT_R : + case KEY_CONTROL_L : + case KEY_CONTROL_R : + case KEY_ALT_L : + case KEY_ALT_R : + case KEY_RESIZE : + break; + default: + done = TRUE; + break; + } + } while (!done); + return c; +} +#define GetChar() myGetChar() +#endif + #if !defined(GetChar) && defined(SNAKE) #define GetChar() wgetch(LYwin) #endif @@ -713,7 +743,7 @@ #if !defined(GetChar) #if HAVE_KEYPAD -#define GetChar getch +#define GetChar() getch() #else #ifndef USE_GETCHAR #define USE_GETCHAR @@ -2571,6 +2601,30 @@ return TRUE; } return FALSE; +} + +/* + * Escape unsafe characters in startfile, except for lynx internal URLs. + */ +PUBLIC void LYEscapeStartfile ARGS1( + char **, buffer) +{ + if (!LYTrimStartfile(*buffer)) { + char *escaped = HTEscapeUnsafe(*buffer); + StrAllocCopy(*buffer, escaped); + FREE(escaped); + } +} + +/* + * Trim all blanks from startfile, except for lynx internal URLs. + */ +PUBLIC void LYTrimAllStartfile ARGS1( + char *, buffer) +{ + if (!LYTrimStartfile(buffer)) { + LYRemoveBlanks(buffer); + } } /* --- ./src/LYStrings.h Sun Jun 3 15:58:00 2001 +++ ../lynx2-8-4/./src/LYStrings.h Thu Feb 13 18:05:32 2003 @@ -294,6 +294,8 @@ extern char *LYElideString PARAMS(( char * str, int cut_pos)); +extern void LYEscapeStartfile PARAMS(( + char ** buffer)); extern void LYLowerCase PARAMS(( char * buffer)); extern void LYUpperCase PARAMS(( @@ -311,6 +313,8 @@ extern void LYTrimLeading PARAMS(( char * buffer)); extern void LYTrimTrailing PARAMS(( + char * buffer)); +extern void LYTrimAllStartfile PARAMS(( char * buffer)); extern BOOLEAN LYTrimStartfile PARAMS(( char * buffer)); --- ./src/LYEdit.c Sun Jun 3 15:58:00 2001 +++ ../lynx2-8-4/./src/LYEdit.c Thu Feb 13 18:05:21 2003 @@ -156,6 +156,7 @@ sprintf(position, "%d", lineno); edit_temporary_file(filename, position, NULL); + result = TRUE; done: /* @@ -165,6 +166,7 @@ *number_sign = '#'; FREE(filename); + CTRACE((tfp, "edit_current_file returns %d\n", result)); return (result); } @@ -173,7 +175,9 @@ char *, position, char *, message) { +#ifdef UNIX struct stat stat_info; +#endif char *format = "%s %s"; char *command = NULL; char *editor_arg = ""; --- ./src/LYCurses.c Sat Jul 7 21:30:13 2001 +++ ../lynx2-8-4/./src/LYCurses.c Thu Feb 13 18:05:37 2003 @@ -548,9 +548,7 @@ } #endif /* USE_COLOR_STYLE */ -#ifndef USE_SLANG PRIVATE BOOL lynx_called_initscr = FALSE; -#endif #if HAVE_USE_DEFAULT_COLORS && USE_DEFAULT_COLORS /* @@ -1250,7 +1248,7 @@ lynx_nl2crlf(TRUE); lynx_enable_mouse (0); #if (!defined(WIN_EX) || defined(__CYGWIN__)) /* @@@ */ - if(LYscreen) { + if(LYscreen || lynx_called_initscr) { endwin(); /* stop curses */ LYDELSCR(); } @@ -1538,7 +1536,7 @@ LYsubwindow(form_window); # ifdef USE_COLOR_STYLE { - attr_t b; + long b; /* Get a proper value for the attribute */ LynxWChangeStyle(form_window, s_menu_bg, STACK_ON); @@ -1593,7 +1591,7 @@ PUBLIC void LYtouchline ARGS1( int, row) { -#if defined(HAVE_WREDRAWLN) +#if defined(HAVE_WREDRAWLN) && !defined(NCURSES_VERSION) wredrawln(LYwin, row, 1); #else #if defined(HAVE_TOUCHLINE) --- ./src/GridText.c Tue Jul 10 13:05:58 2001 +++ ../lynx2-8-4/./src/GridText.c Thu Feb 13 18:05:26 2003 @@ -75,6 +75,11 @@ #define FirstHTLine(text) ((text)->last_line->next) #define LastHTLine(text) ((text)->last_line) +PRIVATE void HText_trimHightext PARAMS(( + HText * text, + BOOLEAN final, + int stop_before)); + #ifdef USE_COLOR_STYLE PRIVATE void LynxResetScreenCache NOARGS { @@ -5257,7 +5262,7 @@ if (a->show_anchor == NO) { /* * The anchor's content is restricted to white - * and special characters, so set it's number + * and special characters, so set its number * and extent to zero, decrement the visible * anchor number counter, and add this anchor * to the hidden links list. - FM @@ -5272,7 +5277,7 @@ /* * The anchor's content is not restricted to white * and special characters, so we'll display the - * content, but shorten it's extent by any trailing + * content, but shorten its extent by any trailing * blank lines we've detected. - FM */ a->extent -= ((BlankExtent < a->extent) ? @@ -5455,7 +5460,7 @@ ** This needs to be done so that display_page finds the anchors in the ** form it expects when it sets the links[] elements. */ -PUBLIC void HText_trimHightext ARGS3( +PRIVATE void HText_trimHightext ARGS3( HText *, text, BOOLEAN, final, int, stop_before) @@ -5677,15 +5682,6 @@ } -/* Dump diagnostics to tfp -*/ -PUBLIC void HText_dump ARGS1( - HText *, text GCC_UNUSED) -{ - CTRACE((tfp, "HText: Dump called\n")); -} - - /* Return the anchor associated with this node */ PUBLIC HTParentAnchor * HText_nodeAnchor ARGS1( @@ -6328,7 +6324,7 @@ * for the first hit with the string indicated by target. If * there is no hit, FALSE is returned. If there is a hit, then * a copy of the line starting at that first hit is loaded into - * *data with all IsSpecial characters stripped, it's offset and + * *data with all IsSpecial characters stripped, its offset and * the printable target length (without IsSpecial, or extra CJK * or utf8 characters) are loaded into *offset and *tLen, and * TRUE is returned. - FM @@ -7736,7 +7732,7 @@ HTLine *, line, int, count) { - BOOL wrapped = FALSE; + int wrapped = 0; TextAnchor *a = line_num_to_anchor(count - 1); int tentative_result = -1; @@ -7756,12 +7752,12 @@ if (LYno_attr_strstr(line->data, target)) { tentative_result = count; break; - } else if (count == start_line && wrapped) { + } else if ((count == start_line && wrapped) || wrapped > 1) { HTUserMsg2(STRING_NOT_FOUND, target); return -1; } else if (line == HTMainText->last_line) { count = 0; - wrapped = TRUE; + wrapped++; } line = line->next; count++; @@ -7779,7 +7775,7 @@ HTLine *, line, int, count) { - BOOL wrapped = FALSE; + int wrapped = 0; TextAnchor *a = line_num_to_anchor(count - 1); int tentative_result = -1; @@ -7799,12 +7795,12 @@ if (LYno_attr_strstr(line->data, target)) { tentative_result = count; break; - } else if (count == start_line && wrapped) { + } else if ((count == start_line && wrapped) || wrapped > 1) { HTUserMsg2(STRING_NOT_FOUND, target); return -1; } else if (line == FirstHTLine(HTMainText)) { count = line_num_in_text(HTMainText, LastHTLine(HTMainText)) + 1; - wrapped = TRUE; + wrapped++; } line = line->prev; count--; @@ -11275,6 +11271,8 @@ return(FALSE); } +#define CanTrimTextArea(c) \ + (LYtrimInputFields ? isspace(c) : ((c) == '\r' || (c) == '\n')) /* * Cleanup new lines coming into a TEXTAREA from an external editor, or a @@ -11301,13 +11299,11 @@ /* * Whack off trailing whitespace from the line. */ - if (LYtrimInputFields) { - for (i = len, p = line + (len - 1); i != 0; p--, i--) { - if (isspace(UCH(*p))) - *p = '\0'; - else - break; - } + for (i = len, p = line + (len - 1); i != 0; p--, i--) { + if (CanTrimTextArea(UCH(*p))) + *p = '\0'; + else + break; } if (strlen (line) != 0) { @@ -12057,11 +12053,9 @@ /* * Nuke any blank lines from the end of the edited data. */ - if (LYtrimInputFields) { - while ((size != 0) - && (isspace(UCH(ebuf[size-1])) || (ebuf[size-1] == '\0'))) - ebuf[--size] = '\0'; - } + while ((size != 0) + && (CanTrimTextArea(UCH(ebuf[size-1])) || (ebuf[size-1] == '\0'))) + ebuf[--size] = '\0'; /* * Copy each line from the temp file into the corresponding anchor --- ./src/GridText.h Sat Jul 7 21:30:13 2001 +++ ../lynx2-8-4/./src/GridText.h Thu Feb 13 18:05:26 2003 @@ -207,10 +207,6 @@ HText * text, BOOL underline, InputFieldData *I)); -extern void HText_trimHightext PARAMS(( - HText * text, - BOOLEAN final, - int stop_before)); extern int HText_SubmitForm PARAMS(( FormInfo * submit_item, document * doc, --- ./src/LYStyle.c Sat Jul 7 21:30:13 2001 +++ ../lynx2-8-4/./src/LYStyle.c Thu Feb 13 18:05:21 2003 @@ -190,7 +190,7 @@ curPair = our_pairs[!!(cA & A_BOLD)][!!(cA & M_BLINK)][fA][bA] - 1; else { curPair = ++colorPairs; - init_pair(curPair, fA, bA); + init_pair((short)curPair, (short)fA, (short)bA); if (fA < MAX_COLOR && bA < MAX_COLOR && curPair < 255) @@ -216,7 +216,7 @@ /* parse a style option of the format * STYLE::FG:BG */ -PRIVATE void parse_style ARGS1(char*,buffer) +PRIVATE void parse_style ARGS1(char*, param) { static struct { char *name; @@ -254,6 +254,7 @@ unsigned n; BOOL found = FALSE; + char *buffer = strdup(param); char *tmp = strchr(buffer, ':'); char *element, *mono, *fg, *bg; @@ -339,6 +340,7 @@ else parse_attributes(mono,fg,bg, DSTYLE_ELEMENTS,element); } + FREE(buffer); } #ifdef LY_FIND_LEAKS @@ -366,6 +368,7 @@ }; unsigned n; char temp[80]; + CTRACE((tfp, "initialize_default_stylesheet\n")); for (n = 0; n < TABLESIZE(table); n++) { parse_style(strcpy(temp, table[n])); } @@ -410,10 +413,11 @@ * need to remember the STYLE: lines we encounter and parse them * after curses has started */ -HTList *lss_styles = NULL; +PRIVATE HTList *lss_styles = NULL; PUBLIC void parse_userstyles NOARGS { + static BOOL first = TRUE; char *name; HTList *cur = lss_styles; @@ -453,9 +457,11 @@ /* Add a STYLE: option line to our list. Process "default:" early for it to have the same semantic as other lines: works at any place of the style file, the first line overrides the later ones. */ -PRIVATE void HStyle_addStyle ARGS1(char*,buffer) +PRIVATE void HStyle_addStyle ARGS1(char*, buffer) { char *name = NULL; + + CTRACE((tfp, "HStyle_addStyle(%s)\n", buffer)); StrAllocCopy(name, buffer); if (lss_styles == NULL) lss_styles = HTList_new(); --- ./src/LYUtils.c Sun Jun 10 21:04:20 2001 +++ ../lynx2-8-4/./src/LYUtils.c Thu Feb 13 18:05:37 2003 @@ -4022,43 +4022,43 @@ { "outside_ftp", &no_outside_ftp, CAN_ANONYMOUS_OUTSIDE_DOMAIN_FTP }, { "inside_rlogin", &no_inside_rlogin, CAN_ANONYMOUS_INSIDE_DOMAIN_RLOGIN }, { "outside_rlogin", &no_outside_rlogin, CAN_ANONYMOUS_OUTSIDE_DOMAIN_RLOGIN }, - { "suspend", &no_suspend, TRUE }, - { "editor", &no_editor, TRUE }, - { "shell", &no_shell, TRUE }, - { "bookmark", &no_bookmark, TRUE }, - { "multibook", &no_multibook, TRUE }, - { "bookmark_exec", &no_bookmark_exec, TRUE }, - { "option_save", &no_option_save, TRUE }, + { "suspend", &no_suspend, FALSE }, + { "editor", &no_editor, FALSE }, + { "shell", &no_shell, FALSE }, + { "bookmark", &no_bookmark, FALSE }, + { "multibook", &no_multibook, FALSE }, + { "bookmark_exec", &no_bookmark_exec, FALSE }, + { "option_save", &no_option_save, FALSE }, { "print", &no_print, CAN_ANONYMOUS_PRINT }, - { "download", &no_download, TRUE }, - { "disk_save", &no_disk_save, TRUE }, + { "download", &no_download, FALSE }, + { "disk_save", &no_disk_save, FALSE }, #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS) { "exec", &no_exec, LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS }, #endif - { "lynxcgi", &no_lynxcgi, TRUE }, - { "exec_frozen", &exec_frozen, TRUE }, + { "lynxcgi", &no_lynxcgi, FALSE }, + { "exec_frozen", &exec_frozen, FALSE }, { "goto", &no_goto, CAN_ANONYMOUS_GOTO }, { "jump", &no_jump, CAN_ANONYMOUS_JUMP }, - { "file_url", &no_file_url, TRUE }, + { "file_url", &no_file_url, FALSE }, #ifndef DISABLE_NEWS - { "news_post", &no_newspost, TRUE }, + { "news_post", &no_newspost, FALSE }, { "inside_news", &no_inside_news, CAN_ANONYMOUS_INSIDE_DOMAIN_READ_NEWS }, { "outside_news", &no_outside_news, CAN_ANONYMOUS_OUTSIDE_DOMAIN_READ_NEWS }, #endif { "mail", &no_mail, CAN_ANONYMOUS_MAIL }, - { "dotfiles", &no_dotfiles, TRUE }, - { "useragent", &no_useragent, TRUE }, + { "dotfiles", &no_dotfiles, FALSE }, + { "useragent", &no_useragent, FALSE }, #ifdef SUPPORT_CHDIR - { "chdir", &no_chdir, TRUE }, + { "chdir", &no_chdir, FALSE }, #endif #ifdef DIRED_SUPPORT - { "dired_support", &no_dired_support, TRUE }, + { "dired_support", &no_dired_support, FALSE }, #ifdef OK_PERMIT - { "change_exec_perms", &no_change_exec_perms, TRUE }, + { "change_exec_perms", &no_change_exec_perms, FALSE }, #endif /* OK_PERMIT */ #endif /* DIRED_SUPPORT */ #ifdef USE_EXTERNALS - { "externals", &no_externals, TRUE }, + { "externals", &no_externals, FALSE }, #endif { "lynxcfg_info", &no_lynxcfg_info, CAN_ANONYMOUS_VIEW_LYNXCFG_INFO }, #ifndef NO_CONFIG_INFO --- ./src/HTInit.c Sun Jun 3 15:58:00 2001 +++ ../lynx2-8-4/./src/HTInit.c Thu Feb 13 18:05:05 2003 @@ -41,7 +41,11 @@ HTSetPresentation("*", "open %s", 1.0, 0.0, 0.0, 0); #else if (LYgetXDisplay() != 0) { /* Must have X11 */ +#ifdef __sgi + HTSetPresentation("application/postscript", "showps %s&", +#else HTSetPresentation("application/postscript", "ghostview %s&", +#endif 1.0, 3.0, 0.0, 0); if (XLoadImageCommand && *XLoadImageCommand) { HTSetPresentation("image/gif", XLoadImageCommand, 1.0, 3.0, 0.0, 0); @@ -54,7 +58,11 @@ HTSetPresentation("image/tiff", XLoadImageCommand, 1.0, 3.0, 0.0, 0); HTSetPresentation("image/jpeg", XLoadImageCommand, 1.0, 3.0, 0.0, 0); } +#ifdef __sgi + HTSetPresentation("video/mpeg", "mediaplayer %s &", 1.0, 3.0, 0.0, 0); +#else HTSetPresentation("video/mpeg", "mpeg_play %s &", 1.0, 3.0, 0.0, 0); +#endif } #endif --- ./CHANGES Tue Jul 17 17:04:37 2001 +++ ../lynx2-8-4/./CHANGES Thu Feb 13 18:05:37 2003 @@ -1,6 +1,57 @@ Changes since Lynx 2.8 release =============================================================================== +extracted from 2002-09-12 (2.8.5dev.9) +* correct inverted logic of restrictions table which made "-restrict=default" + provide incorrect values for several items. This was broken in 2.8.4dev.19 + (reported by Jeff Long and RobertM ) -TD +* correct check for calling endwin() to allow for curses implementations + without newterm (report/patch by Brett Lymn). +* escape blanks and other non-7bit graphic characters in startfile and similar + addresses to guard against interpreting the address as multiple lines + during a GET, etc (report by Ulf Harnhammar ) -TD + +extracted from 2001-10-06 (2.8.5dev.3) +* modify LYtouchline() to avoid using wredrawln() for ncurses, since the + LYwin variable may be a pad much wider than the screen, which is not handled + properly (report by Karl Eichwalder ) -TD +* correct beginning configure script, which was supposed to remove + config.cache, but did not, due to a misplaced line when it was added + 1998-06-04 (prompted by a report by Fr3dY that the + checks for srand/rand did not work) -TD + +extracted from 2001-08-15 (2.8.5dev.2) +* work around defect in move_anchors_in_region() and related logic by changing + default for nested-tables to FALSE when Lynx is not configured for + color-style. The problem is that when an anchor is shifted right by + nested-table logic, if it has a
near the beginning of a table cell and + it happens to be split across a line, its size will not be adjusted properly + (report by Hataguchi Takeshi) -TD +* correct logic used for trimming TEXTAREA introduced in 2.8.4pre.3, which did + not trim carriage-return characters if TRIM_INPUT_FIELDS was false. + (report by Hataguchi Takeshi ) -TD +* correct a bug in search logic which happens with pages shorter than the + screen, due to improper starting-line value sent to search function. Fixed + by adding checks in www_search_backward() and www_search_foreward(), (report + by -Frederic L W Meunier) -TD + +extracted from 2001-07-24 (2.8.5dev.1) +* modify GetChar() definition for PDCurses to ignore key-modifiers which are + passed back from getch() as if they were key codes. Those interfere with + shifted commands such as 'Q' -TD +* modify parse_style() function to operate on a copy of its parameter, to avoid + changing it. Otherwise, when parse_style() is executed as a side effect of + start_curses(), its data is modified and not valid on successive calls. + This bug existed prior to 2.8.4dev.17 -TD +* set return value of edit_current_file() to true if the file is edited. This + forces a reload for example if one edits the current html file, and is needed + to make PDCurses repaint the screen as well (report by vtailor@gte.net, + bug introduced in 2.8.4dev.21) -TD +* add ifdef for wresize() to accommodate FreeBSD 3.x which has resizeterm() but + not wresize(). Also, use a 'long' rather than 'attr_t'. These changes are + needed to build with the 1.8.6ache patches to ncurses (report by Matt + ) -TD + 2001-07-17 (2.8.4rel.1) * remove comment in README.ssl directing people to http://www.moxienet.com/lynx/, since that page is moot with 2.8.4 (report by --- ./configure.in Tue Jul 17 17:04:37 2001 +++ ../lynx2-8-4/./configure.in Thu Feb 13 18:05:26 2003 @@ -4,12 +4,10 @@ dnl and Jim Spath AC_PREREQ(2.12.971222) -rm -f config.cache - AC_INIT(userdefs.h) +rm -f config.cache; touch config.cache CONFIG_H=lynx_cfg.h AC_CONFIG_HEADER($CONFIG_H:config.hin) - CF_CHECK_CACHE PACKAGE=lynx @@ -610,7 +608,7 @@ newpad \ newterm \ pnoutrefresh \ - resizeterm \ + wresize resizeterm \ touchline \ touchwin \ use_default_colors \ --- ./lynx.cfg Sat Jul 14 22:06:16 2001 +++ ../lynx2-8-4/./lynx.cfg Thu Feb 13 18:05:05 2003 @@ -42,7 +42,7 @@ # # Then in ~/lynx.cfg: # -# INCLUDE:/usr/local/lib/lynx.cfg +# INCLUDE:/usr/freeware/lib/lynx-2.8/lynx.cfg # ^^^^^^^^^^^^^^^^^^^^^^^ or whatever is appropriate on your system # and now your own tweaks. # @@ -87,7 +87,7 @@ # # Normally we expect you will connect to a remote site, e.g., the Lynx starting # site: -STARTFILE:http://lynx.browser.org/ +#STARTFILE:http://lynx.browser.org/ # # As an alternative, you may want to use a local URL. A good choice for this is # the user's home directory: @@ -97,6 +97,7 @@ # Your choice of STARTFILE should reflect your site's needs, and be a URL that # you can connect to reliably. Otherwise users will become confused and think # that they cannot run Lynx. +STARTFILE:file://localhost/usr/freeware/lib/lynx-2.8/lynx_help/about_lynx.html .h2 HELPFILE @@ -110,9 +111,10 @@ # http://www.trill-home.com/lynx/lynx_help/lynx_help_main.html # This should be changed to the local path. # -HELPFILE:http://www.trill-home.com/lynx/lynx_help/lynx_help_main.html +#HELPFILE:http://www.trill-home.com/lynx/lynx_help/lynx_help_main.html .ex #HELPFILE:file://localhost/PATH_TO/lynx_help/lynx_help_main.html +HELPFILE:file://localhost/usr/freeware/lib/lynx-2.8/lynx_help/lynx_help_main.html .h2 DEFAULT_INDEX_FILE @@ -274,6 +276,7 @@ # if it was not changed in userdefs.h at compilation time. # #LOCAL_DOMAIN:ukans.edu +#LOCAL_DOMAIN:sgi.com .h1 Character sets @@ -2002,6 +2005,7 @@ # # Unix: # ==== +#GLOBAL_EXTENSION_MAP:/usr/freeware/lib/lynx-2.8/mime.types #GLOBAL_EXTENSION_MAP:/usr/local/lib/mosaic/mime.types # VMS: # === @@ -2186,6 +2190,7 @@ # If you use xli, you may want to add the -quiet flag. # #XLOADIMAGE_COMMAND:xli %s & +#XLOADIMAGE_COMMAND:imgview %s & .h2 VIEWER # MIME types may be assigned to external viewers using @@ -2238,7 +2243,15 @@ #VIEWER:image/jpeg:xli %s&:XWINDOWS #VIEWER:video/mpeg:mpeg_play %s &:XWINDOWS +#VIEWER:application/postscript:showps %s&:XWINDOWS +#VIEWER:image/gif:imgview %s&:XWINDOWS +#VIEWER:image/x-xbm:imgview %s&:XWINDOWS +#VIEWER:image/x-rgb:imgview %s&:XWINDOWS +#VIEWER:image/x-tiff:imgview %s&:XWINDOWS +#VIEWER:image/jpeg:imgview %s&:XWINDOWS +#VIEWER:video/mpeg:mediaplayer %s &:XWINDOWS + .h2 GLOBAL_MAILCAP .h2 PERSONAL_MAILCAP # The global and personal MAILCAP files allow you to specify external @@ -2250,6 +2263,7 @@ # Unix: # ==== #GLOBAL_MAILCAP:/usr/local/lib/mosaic/mailcap +#GLOBAL_MAILCAP:/usr/freeware/lib/lynx-2.8/mailcap # VMS: # === #GLOBAL_MAILCAP:Lynx_Dir:mailcap --- ./config.hin Sun Jun 3 15:58:00 2001 +++ ../lynx2-8-4/./config.hin Thu Feb 13 18:05:20 2003 @@ -150,6 +150,7 @@ #undef HAVE_WAITPID #undef HAVE_WBORDER #undef HAVE_WREDRAWLN +#undef HAVE_WRESIZE #undef HAVE_XCURSES /* CF_PDCURSES_X11 */ #undef HAVE___ARGZ_COUNT /* defined by AM_GNU_GETTEXT */ #undef HAVE___ARGZ_NEXT /* defined by AM_GNU_GETTEXT */ --- ./userdefs.h Sun Jun 3 15:58:00 2001 +++ ../lynx2-8-4/./userdefs.h Thu Feb 13 18:05:05 2003 @@ -276,6 +276,8 @@ #ifndef LYNX_CFG_FILE #ifdef DOSPATH #define LYNX_CFG_FILE "./lynx.cfg" +#elif defined(__sgi) +#define LYNX_CFG_FILE "/usr/freeware/lib/lynx.cfg" #else #define LYNX_CFG_FILE "/usr/local/lib/lynx.cfg" #endif /* DOSPATH */ @@ -289,7 +291,11 @@ * Mappings in these global and personal files override any SUFFIX * definitions in lynx.cfg and built-in defaults from src/HTInit.c. */ +#ifdef __sgi +#define GLOBAL_EXTENSION_MAP "/usr/freeware/lib/lynx-2.8/mime.types" +#else #define GLOBAL_EXTENSION_MAP "/usr/local/lib/mosaic/mime.types" +#endif #define PERSONAL_EXTENSION_MAP ".mime.types" /************************** @@ -299,7 +305,11 @@ * Mappings in these global and personal files override any VIEWER * definitions in lynx.cfg and built-in defaults from src/HTInit.c. */ +#ifdef __sgi +#define GLOBAL_MAILCAP "/usr/freeware/lib/lynx-2.8/mailcap" +#else #define GLOBAL_MAILCAP "/usr/local/lib/mosaic/mailcap" +#endif #define PERSONAL_MAILCAP ".mailcap" /************************** @@ -317,7 +327,11 @@ * use any default viewers for image types. Note that open is used as * the default for NeXT, instead of the XLOADIMAGE_COMMAND definition. */ +#ifdef __sgi +#define XLOADIMAGE_COMMAND "imgview %s &" +#else #define XLOADIMAGE_COMMAND "xli %s &" +#endif /************************** * For UNIX systems, SYSTEM_MAIL and SYSTEM_MAIL_FLAGS are set by the @@ -434,7 +448,11 @@ * -lss command line switch will override these definitions. */ #ifndef LYNX_LSS_FILE +#ifdef __sgi +#define LYNX_LSS_FILE "/usr/freeware/lib/lynx-2.8/lynx.lss" +#else #define LYNX_LSS_FILE "/usr/local/lib/lynx.lss" +#endif #endif /* LYNX_LSS_FILE */ #endif /* VMS OR UNIX */ @@ -456,7 +474,11 @@ * Normally we expect you will connect to a remote site, e.g., the Lynx starting * site: */ +#ifdef __sgi +#define STARTFILE "file://localhost/usr/freeware/lib/lynx-2.8/lynx_help/about_lynx.html" +#else #define STARTFILE "http://lynx.browser.org/" +#endif /* * As an alternative, you may want to use a local URL. A good choice for this * is the user's home directory: @@ -478,7 +500,11 @@ * http://www.trill-home.com/lynx/lynx_help/lynx_help_main.html * This should be changed here or in lynx.cfg to the local path. */ +#ifdef __sgi +#define HELPFILE "http://www.crl.com/~subir/lynx/lynx_help/lynx_help_main.html" +#else #define HELPFILE "http://www.trill-home.com/lynx/lynx_help/lynx_help_main.html" +#endif /* #define HELPFILE "file://localhost/PATH_TO/lynx_help/lynx_help_main.html" */ /***************************** @@ -593,7 +619,11 @@ * if your system does not have utmp capabilities. CHANGE THIS here * or in lynx.cfg. */ +#ifdef __sgi +#define LOCAL_DOMAIN "sgi.com" +#else #define LOCAL_DOMAIN "ukans.edu" +#endif /******************************** * The DEFAULT_CACHE_SIZE specifies the number of WWW documents to be --- ./LYMessages_en.h Sun Jun 3 15:58:00 2001 +++ ../lynx2-8-4/./LYMessages_en.h Thu Feb 13 18:16:05 2003 @@ -6,6 +6,7 @@ */ #ifndef LYMESSAGES_EN_H #define LYMESSAGES_EN_H +#include /******************************************************************* * The following definitions are for status line prompts, messages, or --- ./configure Tue Jul 17 17:04:37 2001 +++ ../lynx2-8-4/./configure Thu Feb 13 18:05:26 2003 @@ -613,9 +613,9 @@ fi +cat config.cache; rm -f config.cache; touch config.cache CONFIG_H=lynx_cfg.h - ac_aux_dir= for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do if test -f $ac_dir/install-sh; then @@ -12241,7 +12241,7 @@ newpad \ newterm \ pnoutrefresh \ - resizeterm \ + wresize resizeterm \ touchline \ touchwin \ use_default_colors \