Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
engine
Manage
Activity
Members
Labels
Plan
Redmine
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
sip
engine
Commits
bc5233ba
Commit
bc5233ba
authored
Jul 6, 2019
by
D-AIRY
Browse files
Options
Downloads
Plain Diff
Merge branch 'branchX' of
https://dev.ds-servers.com/sip/engine
into branchX
parents
bb4f8e71
c4c548b1
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
source/core/file.cpp
+9
-18
9 additions, 18 deletions
source/core/file.cpp
with
9 additions
and
18 deletions
source/core/file.cpp
+
9
−
18
View file @
bc5233ba
...
...
@@ -27,12 +27,9 @@ void CFile::Release()
int
CFile
::
open
(
const
char
*
szPath
,
int
iType
)
{
char
*
mode
;
if
(
iType
==
CORE_FILE_BIN
)
mode
=
"rb"
;
else
if
(
iType
==
CORE_FILE_TEXT
)
mode
=
"r+"
;
m_pFile
=
fopen
(
szPath
,
mode
);
const
char
*
szMode
=
(
iType
==
CORE_FILE_BIN
)
?
"rb"
:
"r+"
;
m_pFile
=
fopen
(
szPath
,
szMode
);
if
(
!
m_pFile
)
return
-
1
;
return
0
;
...
...
@@ -40,12 +37,9 @@ int CFile::open(const char *szPath, int iType)
int
CFile
::
create
(
const
char
*
szPath
,
int
iType
)
{
char
*
mode
;
if
(
iType
==
CORE_FILE_BIN
)
mode
=
"wb"
;
else
if
(
iType
==
CORE_FILE_TEXT
)
mode
=
"w"
;
m_pFile
=
fopen
(
szPath
,
mode
);
const
char
*
szMode
=
(
iType
==
CORE_FILE_BIN
)
?
"wb"
:
"w"
;
m_pFile
=
fopen
(
szPath
,
szMode
);
if
(
!
m_pFile
)
return
-
1
;
return
0
;
...
...
@@ -53,12 +47,9 @@ int CFile::create(const char *szPath, int iType)
int
CFile
::
add
(
const
char
*
szPath
,
int
iType
)
{
char
*
mode
;
if
(
iType
==
CORE_FILE_BIN
)
mode
=
"ab"
;
else
if
(
iType
==
CORE_FILE_TEXT
)
mode
=
"a"
;
m_pFile
=
fopen
(
szPath
,
mode
);
const
char
*
szMode
=
(
iType
==
CORE_FILE_BIN
)
?
"ab"
:
"a"
;
m_pFile
=
fopen
(
szPath
,
szMode
);
if
(
!
m_pFile
)
return
-
1
;
return
0
;
...
...
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