Skip to content
Snippets Groups Projects
Commit 019aeb20 authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Apparently, Windows headers define (at least) PARITY_NONE

Even when "lean and mean".  Rename enum.
parent 4eff99e9
No related branches found
No related tags found
No related merge requests found
Pipeline #7207 canceled
......@@ -9,6 +9,7 @@ Fix crash when editing blank "extra" bbslist entry
Support copy/paste in BBS list
Show current list path, not default in File Locations
Explicitly set serial port to 8N1
Add support bit data bits, stop bits, and parity
Version 1.2rc6
--------------
......
......@@ -822,7 +822,7 @@ read_item(str_list_t listfile, struct bbslist *entry, char *bbsname, int id, int
entry->stop_bits = iniGetUShortInt(section, NULL, "StopBits", 1);
if (entry->stop_bits < 1 || entry->stop_bits > 2)
entry->stop_bits = 1;
entry->parity = iniGetEnum(section, NULL, "Parity", parity_enum, PARITY_NONE);
entry->parity = iniGetEnum(section, NULL, "Parity", parity_enum, SYNCTERM_PARITY_NONE);
/* Log Stuff */
iniGetSString(section, NULL, "LogFile", "", entry->logfile, sizeof(entry->logfile));
......
......@@ -110,9 +110,9 @@ enum {
};
enum {
PARITY_NONE,
PARITY_EVEN,
PARITY_ODD,
SYNCTERM_PARITY_NONE,
SYNCTERM_PARITY_EVEN,
SYNCTERM_PARITY_ODD,
};
/* NOTE: changing this may require updating sort_order in bbslist.c */
......
......@@ -164,7 +164,7 @@ modem_connect(struct bbslist *bbs)
return -1;
}
}
if (!comSetParity(com, bbs->parity != PARITY_NONE, bbs->parity == PARITY_ODD)) {
if (!comSetParity(com, bbs->parity != SYNCTERM_PARITY_NONE, bbs->parity == SYNCTERM_PARITY_ODD)) {
if (!bbs->hidepopups)
uifcmsg("Cannot Set Parity", "`Cannot Set Parity`\n\n"
"Cannot open the specified serial device.\n");
......@@ -209,7 +209,7 @@ modem_connect(struct bbslist *bbs)
return -1;
}
}
if (!comSetParity(com, bbs->parity != PARITY_NONE, bbs->parity == PARITY_ODD)) {
if (!comSetParity(com, bbs->parity != SYNCTERM_PARITY_NONE, bbs->parity == SYNCTERM_PARITY_ODD)) {
if (!bbs->hidepopups)
uifcmsg("Cannot Set Parity", "`Cannot Set Parity`\n\n"
"Cannot open the specified serial device.\n");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment