Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Synchronet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Main
Synchronet
Commits
36ea52b3
Commit
36ea52b3
authored
1 year ago
by
Rob Swindell
Browse files
Options
Downloads
Patches
Plain Diff
Resolve more warings from GCC 12.2
parent
0e8f3833
No related branches found
No related tags found
1 merge request
!463
MRC mods by Codefenix (2024-10-20)
Pipeline
#4013
passed
1 year ago
Stage: build
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
xtrn/dpoker/dpconfig.c
+7
-10
7 additions, 10 deletions
xtrn/dpoker/dpconfig.c
with
7 additions
and
10 deletions
xtrn/dpoker/dpconfig.c
+
7
−
10
View file @
36ea52b3
...
...
@@ -46,10 +46,9 @@ uifcapi_t uifc;
void
read_ini
(
void
)
{
FILE
*
inifile
;
BOOL
tmpbool
;
int
opts
;
int
table
;
char
key_name
[
8
];
char
key_name
[
16
];
inifile
=
fopen
(
"dpoker.ini"
,
"r"
);
iniReadString
(
inifile
,
NULL
,
"ComputerName"
,
"King Drafus"
,
comp_name
);
...
...
@@ -93,10 +92,8 @@ void read_ini(void)
void
write_ini
(
void
)
{
FILE
*
inifile
;
BOOL
tmpbool
;
int
opts
;
int
table
;
char
key_name
[
8
];
char
key_name
[
16
];
str_list_t
inilines
;
if
((
inifile
=
fopen
(
"dpoker.ini"
,
"r"
))
!=
NULL
)
{
...
...
@@ -173,7 +170,7 @@ void edit_table(int table)
opts
[
2
]
=
strdup
(
str
);
sprintf
(
str
,
"Bet Limit %d"
,
tables
[
table
].
bet_limit
);
opts
[
3
]
=
strdup
(
str
);
sprintf
(
str
,
"Table Limit %d"
,
tables
[
table
].
max_total
);
sprintf
(
str
,
"Table Limit %
l
d"
,
tables
[
table
].
max_total
);
opts
[
4
]
=
strdup
(
str
);
opts
[
5
]
=
strdup
(
""
);
sprintf
(
str
,
"Table %d Options"
,
table
+
1
);
...
...
@@ -204,7 +201,7 @@ void edit_table(int table)
tables
[
table
].
bet_limit
=
1
;
break
;
case
4
:
/* Table Limit */
sprintf
(
str
,
"%d"
,
tables
[
table
].
max_total
);
sprintf
(
str
,
"%
l
d"
,
tables
[
table
].
max_total
);
if
(
uifc
.
input
(
WIN_MID
|
WIN_SAV
,
0
,
0
,
"Table Limit"
,
str
,
5
,
K_EDIT
|
K_NUMBER
)
!=-
1
)
tables
[
table
].
max_total
=
atoi
(
str
);
if
(
tables
[
table
].
max_total
<
1
)
...
...
@@ -250,7 +247,7 @@ int main(int argc, char **argv)
opts
[
0
]
=
strdup
(
str
);
sprintf
(
str
,
"Number of Tables %d"
,
num_tables
);
opts
[
1
]
=
strdup
(
str
);
sprintf
(
str
,
"Time allow playing computer %d"
,
time_allowed
);
sprintf
(
str
,
"Time allow playing computer %
l
d"
,
time_allowed
);
opts
[
2
]
=
strdup
(
str
);
sprintf
(
str
,
"Percentage house takes from pot %d%%"
,
skim
);
opts
[
3
]
=
strdup
(
str
);
...
...
@@ -280,7 +277,7 @@ int main(int argc, char **argv)
num_tables
=
1
;
break
;
case
2
:
/* Time allowed */
sprintf
(
str
,
"%d"
,
time_allowed
);
sprintf
(
str
,
"%
l
d"
,
time_allowed
);
if
(
uifc
.
input
(
WIN_MID
|
WIN_SAV
,
0
,
0
,
"Time allowed computer"
,
str
,
5
,
K_EDIT
|
K_NUMBER
)
!=-
1
)
time_allowed
=
atoi
(
str
);
if
(
time_allowed
>
86400
||
time_allowed
<
0
)
...
...
@@ -298,7 +295,7 @@ int main(int argc, char **argv)
case
4
:
/* Table configuration */
while
(
1
)
{
for
(
i
=
0
;
i
<
num_tables
;
i
++
)
{
sprintf
(
str
,
"Table %-2d (%u/%u/%u)"
,
i
+
1
sprintf
(
str
,
"Table %-2d (%u/%u/%
l
u)"
,
i
+
1
,
tables
[
i
].
ante
,
tables
[
i
].
bet_limit
,
tables
[
i
].
max_total
);
topts
[
i
]
=
strdup
(
str
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment