Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
4cbf4705
Commit
4cbf4705
authored
Mar 18, 2021
by
Hugh McMaster
Committed by
Alexandre Julliard
Mar 18, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reg: Move 'import' syntax checks to reg_import().
Signed-off-by:
Hugh McMaster
<
hugh.mcmaster@outlook.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
8801118e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
11 deletions
+13
-11
import.c
programs/reg/import.c
+11
-2
reg.c
programs/reg/reg.c
+1
-8
reg.h
programs/reg/reg.h
+1
-1
No files found.
programs/reg/import.c
View file @
4cbf4705
...
...
@@ -983,13 +983,22 @@ cleanup:
return
NULL
;
}
int
reg_import
(
const
WCHAR
*
filename
)
int
reg_import
(
int
argc
,
WCHAR
*
argvW
[]
)
{
WCHAR
*
filename
,
*
pos
;
FILE
*
fp
;
static
const
WCHAR
rb_mode
[]
=
{
'r'
,
'b'
,
0
};
BYTE
s
[
2
];
struct
parser
parser
;
WCHAR
*
pos
;
if
(
argc
>
3
)
{
output_message
(
STRING_INVALID_SYNTAX
);
output_message
(
STRING_FUNC_HELP
,
wcsupr
(
argvW
[
1
]));
return
1
;
}
filename
=
argvW
[
2
];
fp
=
_wfopen
(
filename
,
rb_mode
);
if
(
!
fp
)
...
...
programs/reg/reg.c
View file @
4cbf4705
...
...
@@ -389,15 +389,8 @@ int __cdecl wmain(int argc, WCHAR *argvW[])
return
0
;
}
if
(
op
==
REG_IMPORT
&&
argc
>
3
)
{
output_message
(
STRING_INVALID_SYNTAX
);
output_message
(
STRING_FUNC_HELP
,
wcsupr
(
argvW
[
1
]));
return
1
;
}
if
(
op
==
REG_IMPORT
)
return
reg_import
(
arg
vW
[
2
]
);
return
reg_import
(
arg
c
,
argvW
);
if
(
op
==
REG_EXPORT
)
return
reg_export
(
argc
,
argvW
);
...
...
programs/reg/reg.h
View file @
4cbf4705
...
...
@@ -56,7 +56,7 @@ int reg_delete(HKEY root, WCHAR *path, WCHAR *key_name, WCHAR *value_name,
int
reg_export
(
int
argc
,
WCHAR
*
argv
[]);
/* import.c */
int
reg_import
(
const
WCHAR
*
filename
);
int
reg_import
(
int
argc
,
WCHAR
*
argvW
[]
);
/* query.c */
int
reg_query
(
HKEY
root
,
WCHAR
*
path
,
WCHAR
*
key_name
,
WCHAR
*
value_name
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment