Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
d4e04dcc
Commit
d4e04dcc
authored
Jan 19, 2015
by
jean-pierre charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix bugs detected by Cppcheck.
parent
79e2a414
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
3 deletions
+5
-3
opengl_gal.cpp
common/gal/opengl/opengl_gal.cpp
+2
-1
autosel.cpp
cvpcb/autosel.cpp
+1
-1
class_pcb_text.cpp
pcbnew/class_pcb_text.cpp
+1
-1
cross-probing.cpp
pcbnew/cross-probing.cpp
+1
-0
No files found.
common/gal/opengl/opengl_gal.cpp
View file @
d4e04dcc
...
@@ -812,10 +812,11 @@ void OPENGL_GAL::drawLineQuad( const VECTOR2D& aStartPoint, const VECTOR2D& aEnd
...
@@ -812,10 +812,11 @@ void OPENGL_GAL::drawLineQuad( const VECTOR2D& aStartPoint, const VECTOR2D& aEnd
VECTOR2D
startEndVector
=
aEndPoint
-
aStartPoint
;
VECTOR2D
startEndVector
=
aEndPoint
-
aStartPoint
;
double
lineLength
=
startEndVector
.
EuclideanNorm
();
double
lineLength
=
startEndVector
.
EuclideanNorm
();
double
scale
=
0.5
*
lineWidth
/
lineLength
;
if
(
lineLength
<=
0.0
)
if
(
lineLength
<=
0.0
)
return
;
return
;
double
scale
=
0.5
*
lineWidth
/
lineLength
;
// The perpendicular vector also needs transformations
// The perpendicular vector also needs transformations
glm
::
vec4
vector
=
currentManager
->
GetTransformation
()
*
glm
::
vec4
vector
=
currentManager
->
GetTransformation
()
*
...
...
cvpcb/autosel.cpp
View file @
d4e04dcc
...
@@ -218,7 +218,7 @@ void CVPCB_MAINFRAME::AutomaticFootprintMatching( wxCommandEvent& event )
...
@@ -218,7 +218,7 @@ void CVPCB_MAINFRAME::AutomaticFootprintMatching( wxCommandEvent& event )
bool
equ_is_unique
=
true
;
bool
equ_is_unique
=
true
;
unsigned
next
=
idx
+
1
;
unsigned
next
=
idx
+
1
;
unsigned
previous
=
idx
-
1
;
int
previous
=
idx
-
1
;
if
(
next
<
equiv_List
.
size
()
&&
if
(
next
<
equiv_List
.
size
()
&&
equivItem
.
m_ComponentValue
==
equiv_List
[
next
].
m_ComponentValue
)
equivItem
.
m_ComponentValue
==
equiv_List
[
next
].
m_ComponentValue
)
...
...
pcbnew/class_pcb_text.cpp
View file @
d4e04dcc
...
@@ -74,7 +74,7 @@ void TEXTE_PCB::Copy( TEXTE_PCB* source )
...
@@ -74,7 +74,7 @@ void TEXTE_PCB::Copy( TEXTE_PCB* source )
m_Bold
=
source
->
m_Bold
;
m_Bold
=
source
->
m_Bold
;
m_HJustify
=
source
->
m_HJustify
;
m_HJustify
=
source
->
m_HJustify
;
m_VJustify
=
source
->
m_VJustify
;
m_VJustify
=
source
->
m_VJustify
;
m_MultilineAllowed
=
m_MultilineAllowed
;
m_MultilineAllowed
=
source
->
m_MultilineAllowed
;
m_Text
=
source
->
m_Text
;
m_Text
=
source
->
m_Text
;
}
}
...
...
pcbnew/cross-probing.cpp
View file @
d4e04dcc
...
@@ -45,6 +45,7 @@ void PCB_EDIT_FRAME::ExecuteRemoteCommand( const char* cmdline )
...
@@ -45,6 +45,7 @@ void PCB_EDIT_FRAME::ExecuteRemoteCommand( const char* cmdline )
wxPoint
pos
;
wxPoint
pos
;
strncpy
(
line
,
cmdline
,
sizeof
(
line
)
-
1
);
strncpy
(
line
,
cmdline
,
sizeof
(
line
)
-
1
);
line
[
sizeof
(
line
)
-
1
]
=
0
;
idcmd
=
strtok
(
line
,
"
\n\r
"
);
idcmd
=
strtok
(
line
,
"
\n\r
"
);
text
=
strtok
(
NULL
,
"
\n\r
"
);
text
=
strtok
(
NULL
,
"
\n\r
"
);
...
...
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