Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
OpenBoard
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lifo
Nicolas Ollinger
OpenBoard
Commits
429e6460
Commit
429e6460
authored
May 16, 2013
by
Claudio Valerio
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
some leaks fixed and cosmetics changes
parent
d3ca55c9
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
13 deletions
+29
-13
UBCFFSubsetAdaptor.cpp
src/adaptors/UBCFFSubsetAdaptor.cpp
+6
-2
UBExportCFF.cpp
src/adaptors/UBExportCFF.cpp
+3
-3
UBSvgSubsetAdaptor.cpp
src/adaptors/UBSvgSubsetAdaptor.cpp
+1
-1
UBGraphicsTextItemDelegate.cpp
src/domain/UBGraphicsTextItemDelegate.cpp
+1
-1
UBCryptoUtils.cpp
src/frameworks/UBCryptoUtils.cpp
+18
-6
No files found.
src/adaptors/UBCFFSubsetAdaptor.cpp
View file @
429e6460
...
@@ -1215,13 +1215,17 @@ UBGraphicsGroupContainerItem *UBCFFSubsetAdaptor::UBCFFSubsetReader::parseIwbGro
...
@@ -1215,13 +1215,17 @@ UBGraphicsGroupContainerItem *UBCFFSubsetAdaptor::UBCFFSubsetReader::parseIwbGro
pStrokesGroup
->
addToGroup
(
poly
);
pStrokesGroup
->
addToGroup
(
poly
);
}
}
}
}
if
(
currentStroke
->
polygons
().
empty
())
if
(
currentStroke
->
polygons
().
empty
())
{
delete
currentStroke
;
delete
currentStroke
;
currentStroke
=
NULL
;
}
if
(
pStrokesGroup
->
childItems
().
count
())
if
(
pStrokesGroup
->
childItems
().
count
())
mCurrentScene
->
addItem
(
pStrokesGroup
);
mCurrentScene
->
addItem
(
pStrokesGroup
);
else
else
{
delete
pStrokesGroup
;
delete
pStrokesGroup
;
pStrokesGroup
=
NULL
;
}
if
(
pStrokesGroup
)
if
(
pStrokesGroup
)
{
{
...
...
src/adaptors/UBExportCFF.cpp
View file @
429e6460
...
@@ -51,10 +51,10 @@ QString UBExportCFF::exportExtention()
...
@@ -51,10 +51,10 @@ QString UBExportCFF::exportExtention()
void
UBExportCFF
::
persist
(
UBDocumentProxy
*
pDocument
)
void
UBExportCFF
::
persist
(
UBDocumentProxy
*
pDocument
)
{
{
QString
src
=
pDocument
->
persistencePath
();
if
(
!
pDocument
)
if
(
!
pDocument
)
return
;
return
;
QString
src
=
pDocument
->
persistencePath
();
QString
filename
=
askForFileName
(
pDocument
,
tr
(
"Export as IWB File"
));
QString
filename
=
askForFileName
(
pDocument
,
tr
(
"Export as IWB File"
));
...
@@ -82,4 +82,4 @@ void UBExportCFF::persist(UBDocumentProxy* pDocument)
...
@@ -82,4 +82,4 @@ void UBExportCFF::persist(UBDocumentProxy* pDocument)
}
}
}
}
\ No newline at end of file
src/adaptors/UBSvgSubsetAdaptor.cpp
View file @
429e6460
...
@@ -1553,7 +1553,7 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::polygonItemToSvgPolygon(UBGraphicsPo
...
@@ -1553,7 +1553,7 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::polygonItemToSvgPolygon(UBGraphicsPo
QPolygonF
polygon
=
polygonItem
->
polygon
();
QPolygonF
polygon
=
polygonItem
->
polygon
();
int
pointsCount
=
polygon
.
size
();
int
pointsCount
=
polygon
.
size
();
if
(
po
lygonItem
&&
po
intsCount
>
0
)
if
(
pointsCount
>
0
)
{
{
mXmlWriter
.
writeStartElement
(
"polygon"
);
mXmlWriter
.
writeStartElement
(
"polygon"
);
...
...
src/domain/UBGraphicsTextItemDelegate.cpp
View file @
429e6460
...
@@ -132,7 +132,7 @@ void UBGraphicsTextItemDelegate::customize(QFontDialog &fontDialog)
...
@@ -132,7 +132,7 @@ void UBGraphicsTextItemDelegate::customize(QFontDialog &fontDialog)
fontDialog
.
setStyleSheet
(
"background-color: white;"
);
fontDialog
.
setStyleSheet
(
"background-color: white;"
);
}
}
QListView
*
fontNameListView
;
QListView
*
fontNameListView
=
NULL
;
QList
<
QListView
*>
listViews
=
fontDialog
.
findChildren
<
QListView
*>
();
QList
<
QListView
*>
listViews
=
fontDialog
.
findChildren
<
QListView
*>
();
if
(
listViews
.
count
()
>
0
)
if
(
listViews
.
count
()
>
0
)
{
{
...
...
src/frameworks/UBCryptoUtils.cpp
View file @
429e6460
...
@@ -68,15 +68,21 @@ QString UBCryptoUtils::symetricEncrypt(const QString& clear)
...
@@ -68,15 +68,21 @@ QString UBCryptoUtils::symetricEncrypt(const QString& clear)
int
paddingLength
=
0
;
int
paddingLength
=
0
;
unsigned
char
*
ciphertext
=
(
unsigned
char
*
)
malloc
(
cipheredLength
);
unsigned
char
*
ciphertext
=
(
unsigned
char
*
)
malloc
(
cipheredLength
);
if
(
!
EVP_EncryptInit_ex
(
&
mAesEncryptContext
,
NULL
,
NULL
,
NULL
,
NULL
))
if
(
!
EVP_EncryptInit_ex
(
&
mAesEncryptContext
,
NULL
,
NULL
,
NULL
,
NULL
)){
free
(
ciphertext
);
return
QString
();
return
QString
();
}
if
(
!
EVP_EncryptUpdate
(
&
mAesEncryptContext
,
ciphertext
,
&
cipheredLength
,
(
unsigned
char
*
)
clearData
.
data
(),
clearData
.
length
()))
if
(
!
EVP_EncryptUpdate
(
&
mAesEncryptContext
,
ciphertext
,
&
cipheredLength
,
(
unsigned
char
*
)
clearData
.
data
(),
clearData
.
length
())){
free
(
ciphertext
);
return
QString
();
return
QString
();
}
/* update ciphertext with the final remaining bytes */
/* update ciphertext with the final remaining bytes */
if
(
!
EVP_EncryptFinal_ex
(
&
mAesEncryptContext
,
ciphertext
+
cipheredLength
,
&
paddingLength
))
if
(
!
EVP_EncryptFinal_ex
(
&
mAesEncryptContext
,
ciphertext
+
cipheredLength
,
&
paddingLength
)){
free
(
ciphertext
);
return
QString
();
return
QString
();
}
QByteArray
cipheredData
((
const
char
*
)
ciphertext
,
cipheredLength
+
paddingLength
);
QByteArray
cipheredData
((
const
char
*
)
ciphertext
,
cipheredLength
+
paddingLength
);
...
@@ -94,14 +100,20 @@ QString UBCryptoUtils::symetricDecrypt(const QString& encrypted)
...
@@ -94,14 +100,20 @@ QString UBCryptoUtils::symetricDecrypt(const QString& encrypted)
int
paddingLength
=
0
;
int
paddingLength
=
0
;
unsigned
char
*
plaintext
=
(
unsigned
char
*
)
malloc
(
encryptedLength
);
unsigned
char
*
plaintext
=
(
unsigned
char
*
)
malloc
(
encryptedLength
);
if
(
!
EVP_DecryptInit_ex
(
&
mAesDecryptContext
,
NULL
,
NULL
,
NULL
,
NULL
))
if
(
!
EVP_DecryptInit_ex
(
&
mAesDecryptContext
,
NULL
,
NULL
,
NULL
,
NULL
)){
free
(
plaintext
);
return
QString
();
return
QString
();
}
if
(
!
EVP_DecryptUpdate
(
&
mAesDecryptContext
,
plaintext
,
&
encryptedLength
,
(
const
unsigned
char
*
)
encryptedData
.
data
(),
encryptedData
.
length
()))
if
(
!
EVP_DecryptUpdate
(
&
mAesDecryptContext
,
plaintext
,
&
encryptedLength
,
(
const
unsigned
char
*
)
encryptedData
.
data
(),
encryptedData
.
length
())){
free
(
plaintext
);
return
QString
();
return
QString
();
}
if
(
!
EVP_DecryptFinal_ex
(
&
mAesDecryptContext
,
plaintext
+
encryptedLength
,
&
paddingLength
))
if
(
!
EVP_DecryptFinal_ex
(
&
mAesDecryptContext
,
plaintext
+
encryptedLength
,
&
paddingLength
)){
free
(
plaintext
);
return
QString
();
return
QString
();
}
int
len
=
encryptedLength
+
paddingLength
;
int
len
=
encryptedLength
+
paddingLength
;
QByteArray
clearData
((
const
char
*
)
plaintext
,
len
);
QByteArray
clearData
((
const
char
*
)
plaintext
,
len
);
...
...
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