| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | [2/2] Msged patches from 4.1 to 4.2b1 |
*** 4.1\dialogs.c Sun Feb 2 04:10:00 1997
--- 4.2b\dialogs.c Wed Feb 5 16:46:32 1997
***************
*** 175,181 ****
SW->hardquote = ck2.down;
SW->msgids = ck3.down;
SW->opusdate = ck4.down;
! SW->seenbys = ck5.down;
SW->confirmations = ck6.down;
SW->use_lastr = ck7.down;
SW->usepid = ck8.down;
--- 175,181 ----
SW->hardquote = ck2.down;
SW->msgids = ck3.down;
SW->opusdate = ck4.down;
! SW->showseenbys = ck5.down;
SW->confirmations = ck6.down;
SW->use_lastr = ck7.down;
SW->usepid = ck8.down;
***************
*** 203,209 ****
ck2.down = (unsigned char)SW->hardquote;
ck3.down = (unsigned char)SW->msgids;
ck4.down = (unsigned char)SW->opusdate;
! ck5.down = (unsigned char)SW->seenbys;
ck6.down = (unsigned char)SW->confirmations;
ck7.down = (unsigned char)SW->use_lastr;
ck8.down = (unsigned char)SW->usepid;
--- 203,209 ----
ck2.down = (unsigned char)SW->hardquote;
ck3.down = (unsigned char)SW->msgids;
ck4.down = (unsigned char)SW->opusdate;
! ck5.down = (unsigned char)SW->showseenbys;
ck6.down = (unsigned char)SW->confirmations;
ck7.down = (unsigned char)SW->use_lastr;
ck8.down = (unsigned char)SW->usepid;
*** 4.1\config.c Sun Feb 2 04:10:00 1997
--- 4.2b\config.c Wed Feb 5 16:52:08 1997
***************
*** 236,241 ****
--- 236,243 ----
"NetmailVia",
"DomainOrigin",
"RightNextUnreadArea",
+ "ShowOrigins",
+ "ShowTearlines",
NULL
};
***************
*** 270,275 ****
--- 272,279 ----
#define CFG_SW_NETMAILVIA 28
#define CFG_SW_DOMAINORIGIN 29
#define CFG_SW_RIGHTNEXTUNREADAREA 30
+ #define CFG_SW_SHOWORIGINS 31
+ #define CFG_SW_SHOWTEARLINES 32
/* Strips leading whitespaces from a string. */
***************
*** 410,416 ****
break;
case CFG_SW_SEENBYS:
! SW->seenbys = OnOff;
break;
case CFG_SW_SHOWNOTES:
--- 414,428 ----
break;
case CFG_SW_SEENBYS:
! SW->showseenbys = OnOff;
! break;
!
! case CFG_SW_SHOWORIGINS:
! SW->showorigins = OnOff;
! break;
!
! case CFG_SW_SHOWTEARLINES:
! SW->showtearlines = OnOff;
break;
case CFG_SW_SHOWNOTES:
***************
*** 2031,2041 ****
printf("External editor : %s\n", ST->editorName);
printf("QuickBBS path : %s\n", ST->quickbbs);
printf("\n");
! printf("Areas : %d areas found\n",
SW->areas);
printf("Generate MSGIDs : %s\n", SW->msgids ?
szYes : szNo);
printf("Generate Opus time stamps : %s\n", SW->opusdate
? szYes : szNo);
printf("Show hidden lines : %s\n", SW->shownotes
? szYes : szNo);
! printf("Show SEEN-BY lines : %s\n", SW->seenbys ?
szYes : szNo);
printf("Confirm deletes, aborts : %s\n",
SW->confirmations ? szYes : szNo);
printf("Show date arrived : %s\n",
SW->datearrived ? szYes : szNo);
printf("Show current address : %s\n", SW->showaddr
? szYes : szNo);
--- 2043,2055 ----
printf("External editor : %s\n", ST->editorName);
printf("QuickBBS path : %s\n", ST->quickbbs);
printf("\n");
! printf("Areas : %d area%s
configured\n", SW->areas, SW->areas == 1 ? "" :
"s");
printf("Generate MSGIDs : %s\n", SW->msgids ?
szYes : szNo);
printf("Generate Opus time stamps : %s\n", SW->opusdate
? szYes : szNo);
printf("Show hidden lines : %s\n", SW->shownotes
? szYes : szNo);
! printf("Show SEEN-BY lines : %s\n",
SW->showseenbys ? szYes : szNo);
! printf("Show origin lines : %s\n",
SW->showorigins ? szYes : szNo);
! printf("Show tearlines : %s\n",
SW->showtearlines ? szYes : szNo);
printf("Confirm deletes, aborts : %s\n",
SW->confirmations ? szYes : szNo);
printf("Show date arrived : %s\n",
SW->datearrived ? szYes : szNo);
printf("Show current address : %s\n", SW->showaddr
? szYes : szNo);
*** 4.1\makemsgn.c Sun Feb 2 04:10:00 1997
--- 4.2b\makemsgn.c Wed Feb 5 17:24:30 1997
***************
*** 19,24 ****
--- 19,26 ----
#endif
#endif
+ #include
+
#ifdef OS2
#include
#endif
***************
*** 33,39 ****
#include "strextra.h"
#include "memextra.h"
! #if defined(MSDOS) && !defined(NODOSSWAP)
#include "spawn.h"
#endif
--- 35,41 ----
#include "strextra.h"
#include "memextra.h"
! #if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
#include "spawn.h"
#endif
***************
*** 62,70 ****
static int sent_msg(void)
{
! int ret;
! ret = ChoiceBox("", "WARNING: This message has already
been sent! Continue?", "Yes", "No", NULL);
! return ret == ID_ONE ? 1 : 0;
}
/*
--- 64,72 ----
static int sent_msg(void)
{
! int rc;
! rc = ChoiceBox("", "WARNING: This message has already
been sent! Continue?", "Yes", "No", NULL);
! return rc == ID_ONE ? 1 : 0;
}
/*
***************
*** 437,442 ****
--- 439,445 ----
break;
case ABORT:
+ ChoiceBox("", "Message was aborted.", "
Ok ", NULL, NULL);
scan_base = 1;
break;
}
***************
*** 514,519 ****
--- 517,523 ----
break;
case ABORT:
+ ChoiceBox("", "Message was aborted.", "
Ok ", NULL, NULL);
break;
}
***************
*** 2023,2075 ****
scan_base = TRUE; /* reopen the base when we get back */
}
- #if defined(MSDOS) && !defined(NODOSSWAP)
-
- /*
- * These swap routines imply the use of Thomas Wagner's EXEC module
- * somewhere in the executable. If you don't have this (it's free, and
- * PD), then simply define NODOSSWAP.
- */
-
- /* Return codes (only upper byte significant) */
-
- #define RC_PREPERR 0x0100
- #define RC_NOFILE 0x0200
- #define RC_EXECERR 0x0300
- #define RC_ENVERR 0x0400
- #define RC_SWAPERR 0x0500
-
- /* Swap method and option flags */
-
- #define USE_EMS 0x01
- #define USE_XMS 0x02
- #define USE_FILE 0x04
- #define EMS_FIRST 0x00
- #define XMS_FIRST 0x10
- #define HIDE_FILE 0x40
- #define NO_PREALLOC 0x100
- #define CHECK_NET 0x200
-
- #define USE_ALL (USE_EMS | USE_XMS | USE_FILE)
-
- #define SWAP_FILENAME "$msged.swp"
-
- /* internal flags for prep_swap */
-
- #define CREAT_TEMP 0x0080
- #define DONT_SWAP_ENV 0x4000
-
- #endif
-
- #if 0
-
static void spawn_command(char *cmdline)
{
#if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
int rc;
char swapfn[PATHLEN];
char **envp = environ, **env, *envbuf, *envptr, *ep;
! int swapping = USE_ALL | HIDE_FILE;
int envlen = 0;
if (envp != NULL)
--- 2027,2039 ----
scan_base = TRUE; /* reopen the base when we get back */
}
static void spawn_command(char *cmdline)
{
#if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
int rc;
char swapfn[PATHLEN];
char **envp = environ, **env, *envbuf, *envptr, *ep;
! int swapping = USE_ALL | HIDE_FILE | DONT_SWAP_ENV;
int envlen = 0;
if (envp != NULL)
***************
*** 2113,2141 ****
if (rc > -1)
{
! rc = do_spawn(swapping, cmdline, "", envlen, envptr);
}
else
{
! fputs("\nError occured during do_spawn(). Press Enter to
return...", stderr);
while (GetKey() != 13)
{
}
}
-
- #elif defined(PACIFIC)
- spawnl(cmdline, NULL);
- #elif defined(WINNT)
- system(cmdline);
- #elif (defined(__FLAT__) || defined(OS2))
- spawnl(0, cmdline, cmdline, NULL);
#else
! system("");
#endif
}
- #endif
-
static int externalEditor(msg * m)
{
FILE *fq;
--- 2077,2096 ----
if (rc > -1)
{
! rc = do_spawn(swapping, ST->comspec, cmdline, envlen, envptr);
}
else
{
! fprintf(stderr, "\nError occured during do_spawn(); rc=%d.
Press Enter to return...", rc);
while (GetKey() != 13)
{
}
}
#else
! system(cmdline);
#endif
}
static int externalEditor(msg * m)
{
FILE *fq;
***************
*** 2146,2152 ****
size_t linelen;
int hardquote, linenum;
static char tmpfnm[] = "msged.tmp";
! int doformat;
doformat = SW->extformat;
hardquote = 0;
--- 2101,2108 ----
size_t linelen;
int hardquote, linenum;
static char tmpfnm[] = "msged.tmp";
! int doformat, statready;
! struct stat ostat, nstat;
doformat = SW->extformat;
hardquote = 0;
***************
*** 2163,2168 ****
--- 2119,2126 ----
current = current->next;
}
fclose(fq);
+ statready = stat(tmpfnm, &ostat) == 0;
+
maxx = term.NCol;
maxy = term.NRow;
***************
*** 2172,2193 ****
MouseOFF();
cursor(1);
! /*
! * We should really be calling do_spawn() here under MS-DOS,
! * rather than using system() ...
! *
! * - Andrew Clarke (15-Jun-96)
! */
!
sprintf(cmd, "%s %s", ST->editorName, tmpfnm);
! /* spawn_command(cmd); */
! system(cmd);
cursor(0);
MouseON();
WndClose(hWnd);
WndCurr(hCurr);
m->text = clearbuffer(m->text);
fq = fopen(tmpfnm, "r");
--- 2130,2157 ----
MouseOFF();
cursor(1);
! #if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
! sprintf(cmd, "/c %s %s", ST->editorName, tmpfnm);
! #else
sprintf(cmd, "%s %s", ST->editorName, tmpfnm);
! #endif
! spawn_command(cmd);
cursor(0);
MouseON();
WndClose(hWnd);
WndCurr(hCurr);
+ if (statready && stat(tmpfnm, &nstat) == 0 &&
+ ostat.st_mtime == nstat.st_mtime && ostat.st_size ==
nstat.st_size)
+ {
+ /*
+ * Old and new timestamps and file sizes are identical, so no
+ * modifications were performed.
+ */
+ return ABORT;
+ }
+
m->text = clearbuffer(m->text);
fq = fopen(tmpfnm, "r");
***************
*** 2235,2241 ****
* The following checks for << at end of line
* and replaces them with CR and \0.
*/
! linebuf[linelen - 3] = '\x0d';
linebuf[linelen - 2] = '\0';
}
else
--- 2199,2205 ----
* The following checks for << at end of line
* and replaces them with CR and \0.
*/
! linebuf[linelen - 3] = '\r';
linebuf[linelen - 2] = '\0';
}
else
***************
*** 2247,2253 ****
*/
if (linelen > term.NCol - 30 &&
!isquote(linebuf) &&
! !strchr("
!{at}#$%^&*~-_+=:;,./", *linebuf))
{
linebuf[linelen - 1] = '\0';
}
--- 2211,2217 ----
*/
if (linelen > term.NCol - 30 &&
!isquote(linebuf) &&
! !strchr("\01
!{at}#$%^&*~-_+=:;,./", *linebuf))
{
linebuf[linelen - 1] = '\0';
}
***************
*** 2268,2285 ****
fclose(fq);
}
}
if (current == NULL)
return ABORT;
!
! /*
! * At this point, Msged should compare the original datestamp of
! * msged.tmp with the datestamp of msged.tmp after the return from
! * the external editor. If both datestamps are _identical_, the
! * user did not edit the message, so return ABORT. Otherwise return
! * SAVE. Any volunteers?
! *
! * - Andrew Clarke (15-Jun-96)
! */
return SAVE;
}
--- 2232,2242 ----
fclose(fq);
}
}
+
if (current == NULL)
+ {
return ABORT;
! }
return SAVE;
}
*** 4.1\msged.c Sun Feb 2 04:10:00 1997
--- 4.2b\msged.c Wed Feb 5 17:13:46 1997
***************
*** 42,48 ****
#include "makemsgn.h"
#include "dialogs.h"
! #if defined(MSDOS) && !defined(NODOSSWAP)
#include "spawn.h"
#endif
--- 42,48 ----
#include "makemsgn.h"
#include "dialogs.h"
! #if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
#include "spawn.h"
#endif
***************
*** 518,524 ****
{
if (EditHeader(message) == Key_Esc)
{
! if (confirm("Erase Message?"))
{
message = KillMsg(message);
return;
--- 518,524 ----
{
if (EditHeader(message) == Key_Esc)
{
! if (confirm("Cancel?"))
{
message = KillMsg(message);
return;
***************
*** 1470,1476 ****
#if defined(MSDOS) && !defined(__FLAT__)
if (SW->statbar)
{
! sprintf(line, "%c %3ldk ", SC7, (long)(corerem() / 1024));
WndPutsn(maxx - 7, maxy - 1, 7, cm[CM_ITXT], line);
}
#endif
--- 1470,1476 ----
#if defined(MSDOS) && !defined(__FLAT__)
if (SW->statbar)
{
! sprintf(line, "%c %3ldK ", SC7, (long)(corerem() / 1024));
WndPutsn(maxx - 7, maxy - 1, 7, cm[CM_ITXT], line);
}
#endif
***************
*** 1938,1989 ****
message = KillMsg(message);
}
- #if defined(MSDOS) && !defined(NODOSSWAP)
-
- /*
- * These swap routines imply the use of Thomas Wagner's EXEC module
- * somewhere in the executable. If you don't have this (it's free, and
- * PD), then simply define NODOSSWAP.
- */
-
- /* Return codes (only upper byte significant) */
-
- #define RC_PREPERR 0x0100
- #define RC_NOFILE 0x0200
- #define RC_EXECERR 0x0300
- #define RC_ENVERR 0x0400
- #define RC_SWAPERR 0x0500
-
- /* Swap method and option flags */
-
- #define USE_EMS 0x01
- #define USE_XMS 0x02
- #define USE_FILE 0x04
- #define EMS_FIRST 0x00
- #define XMS_FIRST 0x10
- #define HIDE_FILE 0x40
- #define NO_PREALLOC 0x100
- #define CHECK_NET 0x200
-
- #define USE_ALL (USE_EMS | USE_XMS | USE_FILE)
-
- #define SWAP_FILENAME "$msged.swp"
-
- /* internal flags for prep_swap */
-
- #define CREAT_TEMP 0x0080
- #define DONT_SWAP_ENV 0x4000
-
- #endif
-
void shell_to_dos(void)
{
#if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
-
int rc;
char swapfn[PATHLEN];
char **envp = environ, **env, *envbuf, *envptr, *ep;
! int swapping = USE_ALL | HIDE_FILE;
int envlen = 0;
if (envp != NULL)
--- 1938,1950 ----
message = KillMsg(message);
}
void shell_to_dos(void)
{
#if defined(MSDOS) && !defined(NODOSSWAP) && !defined(__FLAT__)
int rc;
char swapfn[PATHLEN];
char **envp = environ, **env, *envbuf, *envptr, *ep;
! int swapping = USE_ALL | HIDE_FILE | DONT_SWAP_ENV;
int envlen = 0;
if (envp != NULL)
***************
*** 2031,2042 ****
}
else
{
! fputs("\nError occured during do_spawn(). Press Enter to
return...", stderr);
while (GetKey() != 13)
{
}
}
-
#elif defined(PACIFIC)
spawnl(ST->comspec, NULL);
#elif defined(__FLAT__) || defined(OS2)
--- 1992,2002 ----
}
else
{
! fprintf(stderr, "\nError occured during do_spawn(); rc=%d.
Press Enter to return...", rc);
while (GetKey() != 13)
{
}
}
#elif defined(PACIFIC)
spawnl(ST->comspec, NULL);
#elif defined(__FLAT__) || defined(OS2)
--- Blue Wave/OS2 v2.30
* Origin: COMM Port OS/2 juge.com 204.89.247.1 (281) 980-9671 (1:106/2000)SEEN-BY: 50/99 54/99 270/101 620/243 711/401 413 430 934 712/407 505 517 623 SEEN-BY: 712/624 713/317 714/906 800/1 @PATH: 106/2000 396/1 270/101 712/624 711/934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.