Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
KDiff3
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
5
Issues
5
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
KDE
KDiff3
Commits
29c895c9
Commit
29c895c9
authored
Sep 22, 2019
by
Michael Reeves
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Drop duplicate existance check
parent
c2467684
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
src/cvsignorelist.cpp
src/cvsignorelist.cpp
+7
-6
No files found.
src/cvsignorelist.cpp
View file @
29c895c9
...
...
@@ -12,6 +12,7 @@
* (at your option) any later version. *
***************************************************************************/
#include "cvsignorelist.h"
#include "TypeUtils.h"
#include <QDir>
#include <QTextStream>
...
...
@@ -35,21 +36,21 @@ void CvsIgnoreList::init(FileAccess& dir, const t_DirectoryList* pDirList)
{
FileAccess
file
(
dir
);
file
.
addPath
(
".cvsignore"
);
qint64
size
=
file
.
exists
()
?
file
.
sizeForReading
()
:
0
;
if
(
size
>
0
&&
size
<=
(
qint64
)
std
::
numeric_limits
<
int
>::
max
()
)
qint64
size
=
file
.
sizeForReading
()
;
if
(
size
>
0
)
{
char
*
buf
=
new
char
[
size
];
if
(
buf
!=
nullptr
)
{
file
.
readFile
(
buf
,
size
);
int
pos1
=
0
;
for
(
int
pos
=
0
;
pos
<=
size
;
++
pos
)
qint64
pos1
=
0
;
for
(
qint64
pos
=
0
;
pos
<=
size
;
++
pos
)
{
if
(
pos
==
size
||
buf
[
pos
]
==
' '
||
buf
[
pos
]
==
'\t'
||
buf
[
pos
]
==
'\n'
||
buf
[
pos
]
==
'\r'
)
{
if
(
pos
>
pos1
)
if
(
pos
>
pos1
&&
pos
-
pos1
<=
TYPE_MAX
(
QtNumberType
)
)
{
addEntry
(
QString
::
fromLatin1
(
&
buf
[
pos1
],
pos
-
pos1
));
addEntry
(
QString
::
fromLatin1
(
&
buf
[
pos1
],
(
QtNumberType
)(
pos
-
pos1
)
));
}
++
pos1
;
}
...
...
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