[Libreoffice-commits] core.git: onlineupdate/source

2023-01-03 Thread Douglas Guptill (via logerrit)
 onlineupdate/source/libmar/sign/nss_secutil.h |5 +
 1 file changed, 1 insertion(+), 4 deletions(-)

New commits:
commit 8a96d90a890812d49ee4f3c45b99aa0110b94d69
Author: Douglas Guptill 
AuthorDate: Sun Jan 1 15:24:51 2023 -0400
Commit: Thorsten Behrens 
CommitDate: Tue Jan 3 14:26:39 2023 +

tdf#143148  Use pragma once instead of include guards

Change-Id: Id4b84b13bf6a467d07ba11ca6bd65495b172e606
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144928
Reviewed-by: Thorsten Behrens 
Tested-by: Thorsten Behrens 

diff --git a/onlineupdate/source/libmar/sign/nss_secutil.h 
b/onlineupdate/source/libmar/sign/nss_secutil.h
index f599fcce573d..5b1772d17994 100644
--- a/onlineupdate/source/libmar/sign/nss_secutil.h
+++ b/onlineupdate/source/libmar/sign/nss_secutil.h
@@ -5,8 +5,7 @@
 /* With the exception of GetPasswordString, this file was
copied from NSS's cmd/lib/secutil.h hg revision 8f011395145e */
 
-#ifndef NSS_SECUTIL_H_
-#define NSS_SECUTIL_H_
+#pragma once
 
 #include "nss.h"
 #include "pk11pub.h"
@@ -39,5 +38,3 @@ static char * quiet_fgets (char *buf, int length, FILE 
*input);
 
 char *
 SECU_GetModulePassword(PK11SlotInfo *slot, PRBool retry, void *arg);
-
-#endif


[Libreoffice-commits] core.git: onlineupdate/source vcl/unx

2020-12-21 Thread Caolán McNamara (via logerrit)
 onlineupdate/source/update/updater/progressui_gtk.cxx |3 ++-
 vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx |4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 1b3589bb4a7da27be9b1ec3573d6dcaa834416b8
Author: Caolán McNamara 
AuthorDate: Sun Dec 20 19:49:36 2020 +
Commit: Caolán McNamara 
CommitDate: Mon Dec 21 09:42:50 2020 +0100

Replace more deprecated gtk_hbox_new/gtk_vbox_new with gtk_box_new

Change-Id: I8a0d36150f6436312beccfdf628fec1a26dc4466
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108060
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/onlineupdate/source/update/updater/progressui_gtk.cxx 
b/onlineupdate/source/update/updater/progressui_gtk.cxx
index 7c3bcfcd8b2d..961e4cdd92b9 100644
--- a/onlineupdate/source/update/updater/progressui_gtk.cxx
+++ b/onlineupdate/source/update/updater/progressui_gtk.cxx
@@ -107,7 +107,8 @@ ShowProgressUI()
 gtk_window_set_icon(GTK_WINDOW(sWin), pixbuf);
 g_object_unref(pixbuf);
 
-GtkWidget *vbox = gtk_vbox_new(TRUE, 6);
+GtkWidget *vbox = gtk_box_new(GTK_ORIENTATION_VERTICAL, 6);
+gtk_box_set_homogeneous(GTK_BOX(vbox), true);
 sLabel = gtk_label_new(strings.info);
 gtk_misc_set_alignment(GTK_MISC(sLabel), 0.0f, 0.0f);
 sProgressBar = gtk_progress_bar_new();
diff --git a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx 
b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx
index f1395f1e5c7a..20ac52da0c03 100644
--- a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx
+++ b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx
@@ -131,7 +131,7 @@ SalGtkFilePicker::SalGtkFilePicker( const uno::Reference< 
uno::XComponentContext
 #endif
 gtk_file_chooser_set_select_multiple( GTK_FILE_CHOOSER( m_pDialog ), false 
);
 
-m_pVBox = gtk_vbox_new( false, 0 );
+m_pVBox = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0);
 
 // We don't want clickable items to have a huge hit-area
 GtkWidget *pHBox = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0);
@@ -173,7 +173,7 @@ SalGtkFilePicker::SalGtkFilePicker( const uno::Reference< 
uno::XComponentContext
 
 for( i = 0; i < LIST_LAST; i++ )
 {
-m_pHBoxs[i] = gtk_hbox_new( false, 0 );
+m_pHBoxs[i] = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0);
 
 m_pAligns[i] = gtk_alignment_new(0, 0, 0, 1);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2020-09-29 Thread Andrea Gelmini (via logerrit)
 onlineupdate/source/libmar/verify/cryptox.c |2 +-
 onlineupdate/source/libmar/verify/cryptox.h |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit ff25b305caec2fad515beb2ad6d5766101845ccf
Author: Andrea Gelmini 
AuthorDate: Sat Sep 26 21:03:50 2020 +0200
Commit: Jan Holesovsky 
CommitDate: Tue Sep 29 15:16:10 2020 +0200

Fix typo in code

It passed "make check" on Linux

Change-Id: Id08fb3de62c55ab24f585b1bd1b9f719c78f91b5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103464
Tested-by: Jenkins
Reviewed-by: Jan Holesovsky 

diff --git a/onlineupdate/source/libmar/verify/cryptox.c 
b/onlineupdate/source/libmar/verify/cryptox.c
index 5cda191dec7e..7cce8bf036fd 100644
--- a/onlineupdate/source/libmar/verify/cryptox.c
+++ b/onlineupdate/source/libmar/verify/cryptox.c
@@ -115,7 +115,7 @@ NSS_VerifySignature(VFYContext * const *ctx,
  * @return CryptoX_Success on success, CryptoX_Error on error.
 */
 CryptoX_Result
-CyprtoAPI_VerifySignature(HCRYPTHASH *hash,
+CryptoAPI_VerifySignature(HCRYPTHASH *hash,
   HCRYPTKEY *pubKey,
   const BYTE *signature,
   DWORD signatureLen)
diff --git a/onlineupdate/source/libmar/verify/cryptox.h 
b/onlineupdate/source/libmar/verify/cryptox.h
index eb8548fa7a4f..b0f00725fdf0 100644
--- a/onlineupdate/source/libmar/verify/cryptox.h
+++ b/onlineupdate/source/libmar/verify/cryptox.h
@@ -117,7 +117,7 @@ CryptoX_Result CryptoAPI_LoadPublicKey(HCRYPTPROV hProv,
 CryptoX_Result CryptoAPI_VerifyBegin(HCRYPTPROV provider, HCRYPTHASH* hash);
 CryptoX_Result CryptoAPI_VerifyUpdate(HCRYPTHASH* hash,
   BYTE *buf, DWORD len);
-CryptoX_Result CyprtoAPI_VerifySignature(HCRYPTHASH *hash,
+CryptoX_Result CryptoAPI_VerifySignature(HCRYPTHASH *hash,
 HCRYPTKEY *pubKey,
 const BYTE *signature,
 DWORD signatureLen);
@@ -137,7 +137,7 @@ CryptoX_Result CyprtoAPI_VerifySignature(HCRYPTHASH *hash,
 #define CryptoX_LoadPublicKey(CryptoHandle, certData, dataSize, publicKey) \
   CryptoAPI_LoadPublicKey(CryptoHandle, (BYTE*)(certData), dataSize, publicKey)
 #define CryptoX_VerifySignature(hash, publicKey, signedData, len) \
-  CyprtoAPI_VerifySignature(hash, publicKey, signedData, len)
+  CryptoAPI_VerifySignature(hash, publicKey, signedData, len)
 #define CryptoX_FreePublicKey(key) \
   CryptDestroyKey(*(key))
 #define CryptoX_FreeCertificate(cert) \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2020-02-16 Thread Muhammet Kara (via logerrit)
 onlineupdate/source/update/updater/updater.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 1bc6f5868fd5e780e70f999144432f30d8f64149
Author: Muhammet Kara 
AuthorDate: Sun Feb 16 21:12:10 2020 +0300
Commit: Muhammet Kara 
CommitDate: Sun Feb 16 22:32:47 2020 +0100

Proper error check for fwrite in updater.cxx

A less-than-zero check for an unsigned value of type size_t
doesn't make sense, and:

If the return value of fwrite differs from the count parameter,
it means that a writing error prevented the function from completing.
In this case, the error indicator (ferror) will be set for the stream.

Change-Id: I344e608b2bc03a4a117fc5cca1acb8e26eda247a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88817
Tested-by: Jenkins
Reviewed-by: Muhammet Kara 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index 006e2ffe5a94..54750afb4218 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -731,8 +731,9 @@ static int ensure_copy(const NS_tchar *path, const NS_tchar 
*dest)
 
 while (written < read)
 {
-size_t chunkWritten = fwrite(buffer, 1, read - written, outfile);
-if (chunkWritten <= 0)
+size_t nCount = read - written;
+size_t chunkWritten = fwrite(buffer, 1, nCount, outfile);
+if (chunkWritten != nCount)
 {
 LOG(("ensure_copy: failed to write the file: " LOG_S ", err: 
%d",
  dest, errno));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2020-02-09 Thread Muhammet Kara (via logerrit)
 onlineupdate/source/update/common/updatehelper.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 057307de1239efd8b526d674f6ebd4a81d7417df
Author: Muhammet Kara 
AuthorDate: Mon Feb 10 01:46:45 2020 +0300
Commit: Muhammet Kara 
CommitDate: Mon Feb 10 01:03:22 2020 +0100

Fix accidental variable shadowing

Was causing the if-check after the loop evaluating to false
always, thus never running inside the if-block. It was
probably never catched because the initial value of  the outer
variable applicationRunningError is always WAIT_TIMEOUT.

This was also causing error codes other than ERROR_SUCCESS
and WAIT_TIMEOUT never being returned from this method.

Change-Id: I068f96cd4d5afd63fe7017062e5ad6af171dcca0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88353
Tested-by: Jenkins
Reviewed-by: Muhammet Kara 

diff --git a/onlineupdate/source/update/common/updatehelper.cxx 
b/onlineupdate/source/update/common/updatehelper.cxx
index 1363fa040eb9..09f857b1a9e9 100644
--- a/onlineupdate/source/update/common/updatehelper.cxx
+++ b/onlineupdate/source/update/common/updatehelper.cxx
@@ -686,7 +686,7 @@ WaitForProcessExit(LPCWSTR filename, DWORD maxSeconds)
 DWORD applicationRunningError = WAIT_TIMEOUT;
 for (DWORD i = 0; i < maxSeconds; i++)
 {
-DWORD applicationRunningError = IsProcessRunning(filename);
+applicationRunningError = IsProcessRunning(filename);
 if (ERROR_NOT_FOUND == applicationRunningError)
 {
 return ERROR_SUCCESS;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source sfx2/source udkapi/com winaccessibility/source xmloff/source

2019-08-19 Thread Andrea Gelmini (via logerrit)
 onlineupdate/source/libmar/verify/mar_verify.c |2 +-
 sfx2/source/bastyp/progress.cxx|2 +-
 udkapi/com/sun/star/reflection/XIdlField2.idl  |4 ++--
 winaccessibility/source/service/AccObject.cxx  |2 +-
 xmloff/source/style/styleexp.cxx   |2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)

New commits:
commit a375b0548428979da950e3da75db6ace0509c643
Author: Andrea Gelmini 
AuthorDate: Mon Aug 19 00:30:29 2019 +0200
Commit: Julien Nabet 
CommitDate: Mon Aug 19 09:40:22 2019 +0200

Fix typos

Change-Id: I33a99be34f41c3583fc6684fc68ba6b76ef2f056
Reviewed-on: https://gerrit.libreoffice.org/77682
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/onlineupdate/source/libmar/verify/mar_verify.c 
b/onlineupdate/source/libmar/verify/mar_verify.c
index bfe3b52768d3..9f33f8badd3e 100644
--- a/onlineupdate/source/libmar/verify/mar_verify.c
+++ b/onlineupdate/source/libmar/verify/mar_verify.c
@@ -209,7 +209,7 @@ mar_extract_and_verify_signatures_fp(FILE *fp,
 return CryptoX_Error;
   }
 
-  /* To protect against invalid MAR files, we assumes that the MAR file
+  /* To protect against invalid MAR files, we assume that the MAR file
  size is less than or equal to MAX_SIZE_OF_MAR_FILE. */
   if (fseeko(fp, 0, SEEK_END)) {
 fprintf(stderr, "ERROR: Could not seek to the end of the MAR file.\n");
diff --git a/sfx2/source/bastyp/progress.cxx b/sfx2/source/bastyp/progress.cxx
index 858ce7e45ae8..ec2942490c9f 100644
--- a/sfx2/source/bastyp/progress.cxx
+++ b/sfx2/source/bastyp/progress.cxx
@@ -347,7 +347,7 @@ SfxProgress* SfxProgress::GetActiveProgress
 (
 SfxObjectShell const * pDocSh /*  the , which should be
   queried after a current ,
-  or 0 if an current SfxProgress for the
+  or 0 if a current SfxProgress for the
   entire application should be obtained.
   The pointer only needs at the time of
   the call to be valid.
diff --git a/udkapi/com/sun/star/reflection/XIdlField2.idl 
b/udkapi/com/sun/star/reflection/XIdlField2.idl
index c01347834c1a..4f21b6ab75cf 100644
--- a/udkapi/com/sun/star/reflection/XIdlField2.idl
+++ b/udkapi/com/sun/star/reflection/XIdlField2.idl
@@ -69,7 +69,7 @@ published interface XIdlField2: 
com::sun::star::reflection::XIdlMember
 value of field
 
 @throws IllegalAccessException
-An com::sun::star::lang::IllegalAccessException
+A com::sun::star::lang::IllegalAccessException
 is thrown if the given object is no interface, enum or compound type;
 or the given object does not have the reflected field.
 */
@@ -90,7 +90,7 @@ published interface XIdlField2: 
com::sun::star::reflection::XIdlMember
value to be set
 
 @throws IllegalAccessException
-An com::sun::star::lang::IllegalAccessException
+A com::sun::star::lang::IllegalAccessException
 is thrown if the given object is no interface or compound type;
 or the given object does not have the reflected field.
 */
diff --git a/winaccessibility/source/service/AccObject.cxx 
b/winaccessibility/source/service/AccObject.cxx
index 96016251a1b0..8a42331d28a5 100644
--- a/winaccessibility/source/service/AccObject.cxx
+++ b/winaccessibility/source/service/AccObject.cxx
@@ -238,7 +238,7 @@ void AccObject::DeleteChild( AccObject* pChild )
 }
 
 /**
-   * In order to windows API WindowFromAccessibleObject,we sometimes to set a 
pure
+   * In order to windows API WindowFromAccessibleObject, we sometimes to set a 
pure
* top window accessible object created by windows system as top ancestor.
* @param.
* @return
diff --git a/xmloff/source/style/styleexp.cxx b/xmloff/source/style/styleexp.cxx
index afffbf832d1a..5d1e722c4247 100644
--- a/xmloff/source/style/styleexp.cxx
+++ b/xmloff/source/style/styleexp.cxx
@@ -260,7 +260,7 @@ bool XMLStyleExport::exportStyle(
 OUString sListName;
 aAny >>= sListName;
 
-/* An direct set empty list style has to be written. Otherwise,
+/* A direct set empty list style has to be written. Otherwise,
this information is lost and causes an error, if the parent
style has a list style set. (#i69523#)
 */
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: onlineupdate/source oox/inc oox/README oox/source opencl/source package/qa qadevOOo/runner qadevOOo/tests

2019-07-23 Thread Andrea Gelmini (via logerrit)
 onlineupdate/source/libmar/src/mar_read.c   |2 
+-
 oox/README  |2 
+-
 oox/inc/drawingml/chart/chartdrawingfragment.hxx|2 
+-
 oox/source/export/chartexport.cxx   |2 
+-
 oox/source/export/preset-definitions-to-shape-types.pl  |2 
+-
 oox/source/ole/axcontrol.cxx|2 
+-
 opencl/source/opencl_device.cxx |2 
+-
 package/qa/ofopxmlstorages/TestHelper.java  |2 
+-
 package/qa/storages/TestHelper.java |4 
++--
 qadevOOo/runner/util/DesktopTools.java  |2 
+-
 qadevOOo/tests/java/ifc/form/validation/_XValidatableFormComponent.java |2 
+-
 qadevOOo/tests/java/ifc/frame/_XFrame.java  |4 
++--
 qadevOOo/tests/java/ifc/frame/_XFrameLoader.java|2 
+-
 qadevOOo/tests/java/ifc/i18n/_XNumberFormatCode.java|2 
+-
 qadevOOo/tests/java/ifc/i18n/_XTransliteration.java |2 
+-
 qadevOOo/tests/java/ifc/lang/_XSingleServiceFactory.java|2 
+-
 qadevOOo/tests/java/ifc/sdb/_XResultSetAccess.java  |2 
+-
 qadevOOo/tests/java/ifc/sdbc/_XResultSetMetaDataSupplier.java   |2 
+-
 qadevOOo/tests/java/ifc/ucb/_XCachedContentResultSetFactory.java|2 
+-
 qadevOOo/tests/java/ifc/ucb/_XCachedContentResultSetStubFactory.java|2 
+-
 20 files changed, 22 insertions(+), 22 deletions(-)

New commits:
commit 650a836d00360ffd0b0c5a97bbaf9fe5513bbf32
Author: Andrea Gelmini 
AuthorDate: Tue Jul 23 20:39:25 2019 +0200
Commit: Andrea Gelmini 
CommitDate: Tue Jul 23 22:19:26 2019 +0200

Fix typos

Change-Id: Iea3bd498b1c8934f37085bdf6df71b073e4a871c
Reviewed-on: https://gerrit.libreoffice.org/76203
Tested-by: Jenkins
Reviewed-by: Andrea Gelmini 

diff --git a/onlineupdate/source/libmar/src/mar_read.c 
b/onlineupdate/source/libmar/src/mar_read.c
index 2815d12e7ccb..2a6238ca23fc 100644
--- a/onlineupdate/source/libmar/src/mar_read.c
+++ b/onlineupdate/source/libmar/src/mar_read.c
@@ -269,7 +269,7 @@ int get_mar_file_info_fp(FILE *fp,
 
   /* Skip to the first index entry past the index size field
  We do it in 2 calls because offsetToIndex + sizeof(uint32_t)
- could oerflow in theory. */
+ could overflow in theory. */
   if (fseek(fp, offsetToIndex, SEEK_SET)) {
 return -1;
   }
diff --git a/oox/README b/oox/README
index d20d3349e789..7f127b617981 100644
--- a/oox/README
+++ b/oox/README
@@ -175,7 +175,7 @@ FUTURE WORK: because we have to make sure that all the 
roundtrips
 like PPTX --> ODP --> PPTX work correctly and doesn't lose data.
 the only problematic part is probably saving custom shapes (ie. not
 presets) to PPTX. that part of code predates work on custom shapes
-and is unable to export general custom shapes yet. it will need a bit
+and is unable to export general custom shapes yet. It will need a bit
 of work as LO has more complex equations than DrawingML. other parts
 should work OK, PPTX --> ODP should work and don't lose any
 data. presets should already survive PPTX --> ODP --> PPTX roundtrip
diff --git a/oox/inc/drawingml/chart/chartdrawingfragment.hxx 
b/oox/inc/drawingml/chart/chartdrawingfragment.hxx
index 9b49c35226d7..897ea60fb7a8 100644
--- a/oox/inc/drawingml/chart/chartdrawingfragment.hxx
+++ b/oox/inc/drawingml/chart/chartdrawingfragment.hxx
@@ -57,7 +57,7 @@ public:
 
 /** Imports the absolute anchor size from the cdr:ext element. */
 voidimportExt( const AttributeList& rAttribs );
-/** Sets an the relative anchor position from the cdr:from or cdr:to 
element. */
+/** Sets the relative anchor position from the cdr:from or cdr:to element. 
*/
 voidsetPos( sal_Int32 nElement, sal_Int32 nParentContext, 
const OUString& rValue );
 
 /** Calculates the resulting shape anchor in EMUs. */
diff --git a/oox/source/export/chartexport.cxx 
b/oox/source/export/chartexport.cxx
index 1acf1795373c..dd9d19651e29 100644
--- a/oox/source/export/chartexport.cxx
+++ b/oox/source/export/chartexport.cxx
@@ -3884,7 +3884,7 @@ void ChartExport::exportView3D()
 if(eChartType == chart::TYPEID_PIE)
 {
 /* In OOXML we get value in 0..90 range for pie chart X rotation , 
whereas we expect it to be in -90..90 range,
-   so we conver that during import. It  is modified in 
View3DConverter::convertFromModel()
+   so we convert that during import. It is modified in 
View3DConverter::convertFromModel()
here we convert it back to 0..90 as we received in import */
nRotationX += 90;  // X rotation (map Chart2 

[Libreoffice-commits] core.git: onlineupdate/source

2019-02-15 Thread Libreoffice Gerrit user
 onlineupdate/source/update/updater/updater.cxx |   15 ++-
 1 file changed, 10 insertions(+), 5 deletions(-)

New commits:
commit eaabda554c7ac5ec814f7eefdb1a57719e590e92
Author: Markus Mohrhard 
AuthorDate: Fri Feb 15 16:37:58 2019 +0100
Commit: Markus Mohrhard 
CommitDate: Fri Feb 15 18:19:53 2019 +0100

work around Werror=format-truncation in onlineupdate for now

Change-Id: I6230cc8c76313b5d180ef3fbebec4bc20b794150
Reviewed-on: https://gerrit.libreoffice.org/67879
Tested-by: Jenkins
Reviewed-by: Markus Mohrhard 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index 3cd4aa890aa0..1166501f575e 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -1604,8 +1604,9 @@ PatchFile::Prepare()
 // extract the patch to a temporary file
 mPatchIndex = sPatchIndex++;
 
-NS_tsnprintf(spath, sizeof(spath)/sizeof(spath[0]),
+int nWrittenBytes = NS_tsnprintf(spath, sizeof(spath)/sizeof(spath[0]),
  NS_T("%s/updating/%d.patch"), gWorkingDirPath, mPatchIndex);
+(void) nWrittenBytes;
 
 NS_tremove(spath);
 
@@ -2491,8 +2492,9 @@ ProcessReplaceRequest()
 // need to have the last-update.log and backup-update.log files moved from 
the
 // old installation directory to the new installation directory.
 NS_tchar tmpLog[MAXPATHLEN];
-NS_tsnprintf(tmpLog, sizeof(tmpLog)/sizeof(tmpLog[0]),
+int nWrittenBytes = NS_tsnprintf(tmpLog, sizeof(tmpLog)/sizeof(tmpLog[0]),
  NS_T("%s/updates/last-update.log"), tmpDir);
+(void) nWrittenBytes;
 if (!NS_taccess(tmpLog, F_OK))
 {
 NS_tchar destLog[MAXPATHLEN];
@@ -2672,7 +2674,7 @@ CheckSignature(ArchiveReader& archiveReader)
 
 // TODO: moggi: needs adaption for LibreOffice
 // These paths need to be adapted for us.
-NS_tsnprintf(updateSettingsPath,
+int nWrittenBytes = NS_tsnprintf(updateSettingsPath,
  sizeof(updateSettingsPath) / 
sizeof(updateSettingsPath[0]),
 #ifdef MACOSX
  NS_T("%s/Contents/Resources/update-settings.ini"),
@@ -2680,6 +2682,7 @@ CheckSignature(ArchiveReader& archiveReader)
  NS_T("%s/update-settings.ini"),
 #endif
  gWorkingDirPath);
+(void) nWrittenBytes;
 MARChannelStringTable MARStrings;
 if (ReadMARChannelIDs(updateSettingsPath, ) != OK)
 {
@@ -2743,8 +2746,9 @@ UpdateThreadFunc(void * /*param*/)
 rv = DoUpdate(archiveReader);
 }
 NS_tchar updatingDir[MAXPATHLEN];
-NS_tsnprintf(updatingDir, 
sizeof(updatingDir)/sizeof(updatingDir[0]),
+int nWrittenBytes = NS_tsnprintf(updatingDir, 
sizeof(updatingDir)/sizeof(updatingDir[0]),
  NS_T("%s/updating"), gWorkingDirPath);
+(void) nWrittenBytes;
 ensure_remove_recursive(updatingDir);
 }
 }
@@ -4452,8 +4456,9 @@ int AddPreCompleteActions(ActionList *list)
 int DoUpdate(ArchiveReader& archiveReader)
 {
 NS_tchar manifest[MAXPATHLEN];
-NS_tsnprintf(manifest, sizeof(manifest)/sizeof(manifest[0]),
+int nWrittenBytes = NS_tsnprintf(manifest, 
sizeof(manifest)/sizeof(manifest[0]),
  NS_T("%s/updating/update.manifest"), gWorkingDirPath);
+(void) nWrittenBytes;
 ensure_parent_dir(manifest);
 
 // extract the manifest
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: onlineupdate/source

2018-11-17 Thread Libreoffice Gerrit user
 onlineupdate/source/libmar/sign/nss_secutil.c |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 1baf55c0ab7cc003225fd9adcaf702a511db575a
Author: Markus Mohrhard 
AuthorDate: Thu Oct 11 00:10:48 2018 +0200
Commit: Markus Mohrhard 
CommitDate: Sun Nov 18 05:20:02 2018 +0100

fix off by one error

BLRG-PT-18-004

Change-Id: I9cd2582aebf2b33d40f23254047c35c8dee90f4b
Reviewed-on: https://gerrit.libreoffice.org/63508
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/onlineupdate/source/libmar/sign/nss_secutil.c 
b/onlineupdate/source/libmar/sign/nss_secutil.c
index 9fe5fe4d49e2..875c14309ec0 100644
--- a/onlineupdate/source/libmar/sign/nss_secutil.c
+++ b/onlineupdate/source/libmar/sign/nss_secutil.c
@@ -122,7 +122,7 @@ SECU_FilePasswd(PK11SlotInfo *slot, PRBool retry, void *arg)
 return 0;  /* no good retrying - the files contents will be the same */
   }
 
-  phrases = PORT_ZAlloc(maxPwdFileSize);
+  phrases = PORT_ZAlloc(maxPwdFileSize + 1);
 
   if (!phrases) {
 return 0; /* out of memory */
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2018-09-10 Thread Libreoffice Gerrit user
 onlineupdate/source/update/updater/updater.cxx |   65 -
 1 file changed, 33 insertions(+), 32 deletions(-)

New commits:
commit 926e4e469d0285ee72f8da80f00370b4b3120417
Author: Jan-Marek Glogowski 
AuthorDate: Fri Sep 7 20:19:42 2018 +0200
Commit: Jan-Marek Glogowski 
CommitDate: Mon Sep 10 11:23:06 2018 +0200

Rename online updater functions and strcmp relpath

Try to be more explicit about the newly allocated absolute path and
the relative offset and actually compare the relative part.

-get_full_path(const NS_tchar *relpath)
+new_absolute_path(const NS_tchar *relpath)

-get_relative_path(const NS_tchar *fullpath)
+get_relative_offset(const NS_tchar *abs_path)

Change-Id: I02abd722fc89a1688502b9c5cd375954f9f0bc05
Reviewed-on: https://gerrit.libreoffice.org/60168
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index a05fd075bd3a..a4d31bdb0eb2 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -301,14 +301,15 @@ EnvHasValue(const char *name)
 #endif
 
 /**
- * Coverts a relative update path to a full path.
+ * Coverts a relative update path to a absolute path related to the working
+ * or install directory. Allocates a new NS_tchar[] based path!
  *
  * @param  relpath
  * The relative path to convert to a full path.
  * @return valid filesystem full path or nullptr if memory allocation fails.
  */
 static NS_tchar*
-get_full_path(const NS_tchar *relpath)
+new_absolute_path(const NS_tchar *relpath)
 {
 NS_tchar *destpath = sStagedUpdate ? gWorkingDirPath : gInstallDirPath;
 size_t lendestpath = NS_tstrlen(destpath);
@@ -358,36 +359,36 @@ bool is_userprofile_in_instdir()
 }
 
 /**
- * Converts a full update path into a relative path; reverses get_full_path.
+ * Get a pointer in the absolute path, relative to the working or install
+ * directory. Returns itself, if not absolute or outside of the directory.
  *
- * @param  fullpath
- * The absolute path to convert into a relative path.
+ * @param  abs_path
+ * An absolute path.
  * return pointer to the location within fullpath where the relative path 
starts
  *or fullpath itself if it already looks relative.
  */
 static const NS_tchar*
-get_relative_path(const NS_tchar *fullpath)
+get_relative_offset(const NS_tchar *abs_path)
 {
 // If the path isn't absolute, just return it as-is.
 #ifdef _WIN32
-if (fullpath[1] != ':' && fullpath[2] != '\\')
+if (abs_path[1] != ':' && abs_path[2] != '\\')
 {
 #else
-if (fullpath[0] != '/')
+if (abs_path[0] != '/')
 {
 #endif
-return fullpath;
+return abs_path;
 }
 
 NS_tchar *prefix = sStagedUpdate ? gWorkingDirPath : gInstallDirPath;
 
-// If the path isn't long enough to be absolute, return it as-is.
-if (NS_tstrlen(fullpath) <= NS_tstrlen(prefix))
-{
-return fullpath;
-}
-
-return fullpath + NS_tstrlen(prefix) + 1;
+size_t len = NS_tstrlen(prefix);
+if (NS_tstrlen(abs_path) <= len)
+return abs_path;
+if (0 != strncmp(abs_path, prefix, len))
+return abs_path;
+return abs_path + len + 1;
 }
 
 /**
@@ -1136,7 +1137,7 @@ RemoveFile::Parse(NS_tchar *line)
 mRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mRelPath.get(), validPath);
 
-mFile.reset(get_full_path(validPath));
+mFile.reset(new_absolute_path(validPath));
 if (!mFile)
 {
 return PARSE_ERROR;
@@ -1264,7 +1265,7 @@ RemoveDir::Parse(NS_tchar *line)
 mRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mRelPath.get(), validPath);
 
-mDir.reset(get_full_path(validPath));
+mDir.reset(new_absolute_path(validPath));
 if (!mDir)
 {
 return PARSE_ERROR;
@@ -1390,7 +1391,7 @@ AddFile::Parse(NS_tchar *line)
 mRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mRelPath.get(), validPath);
 
-mFile.reset(get_full_path(validPath));
+mFile.reset(new_absolute_path(validPath));
 if (!mFile)
 {
 return PARSE_ERROR;
@@ -1586,7 +1587,7 @@ PatchFile::Parse(NS_tchar *line)
 mFileRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mFileRelPath.get(), validPath);
 
-mFile.reset(get_full_path(validPath));
+mFile.reset(new_absolute_path(validPath));
 if (!mFile)
 {
 return PARSE_ERROR;
@@ -1812,7 +1813,7 @@ AddIfFile::Parse(NS_tchar *line)
 {
 // format "" ""
 
-mTestFile.reset(get_full_path(get_valid_path()));
+mTestFile.reset(new_absolute_path(get_valid_path()));
 if (!mTestFile)
 return PARSE_ERROR;
 
@@ -1879,7 +1880,7 @@ AddIfNotFile::Parse(NS_tchar *line)
 {
 // format "" ""
 
-mTestFile.reset(get_full_path(get_valid_path()));
+mTestFile.reset(new_absolute_path(get_valid_path()));
 if 

[Libreoffice-commits] core.git: onlineupdate/source

2018-03-20 Thread Adolfo Jayme Barrientos
 onlineupdate/source/update/updater/progressui_gtk.cxx |4 ++--
 onlineupdate/source/update/updater/progressui_win.cxx |   12 ++--
 2 files changed, 8 insertions(+), 8 deletions(-)

New commits:
commit 6e5a95c34c7d6817389c6d9aeb5206d821963f05
Author: Adolfo Jayme Barrientos 
Date:   Tue Mar 20 05:35:42 2018 -0600

updater: Tone down the geekiness in user-facing strings

Pro tip: The user doesn’t have to know that the updater is a separate 
program.

Change-Id: I04c447a16a322b7f4139e69f6cababc797148bb1

diff --git a/onlineupdate/source/update/updater/progressui_gtk.cxx 
b/onlineupdate/source/update/updater/progressui_gtk.cxx
index 64d8b18d70ba..47d27ea02c17 100644
--- a/onlineupdate/source/update/updater/progressui_gtk.cxx
+++ b/onlineupdate/source/update/updater/progressui_gtk.cxx
@@ -79,8 +79,8 @@ ShowProgressUI()
 StringTable strings;
 if (ReadStrings(ini_path, ) != OK)
 {
-strcpy(strings.title, "LibreOffice Updater");
-strcpy(strings.info, "This program is updating your LibreOffice 
installation.");
+strcpy(strings.title, "LibreOffice Update");
+strcpy(strings.info, "Please wait while we update your installation.");
 }
 
 sWin = gtk_window_new(GTK_WINDOW_TOPLEVEL);
diff --git a/onlineupdate/source/update/updater/progressui_win.cxx 
b/onlineupdate/source/update/updater/progressui_win.cxx
index 24aed2c94247..12a80f3f7c91 100644
--- a/onlineupdate/source/update/updater/progressui_win.cxx
+++ b/onlineupdate/source/update/updater/progressui_win.cxx
@@ -228,15 +228,15 @@ InitProgressUIStrings()
 WCHAR filename[MAX_PATH];
 if (!GetStringsFile(filename))
 {
-strcpy(sUIStrings.title, "LibreOffice Updater");
-strcpy(sUIStrings.info, "This program is updating your LibreOffice 
installation.");
+strcpy(sUIStrings.title, "LibreOffice Update");
+strcpy(sUIStrings.info, "Please wait while we update your 
installation.");
 return 0;
 }
 
 if (_waccess(filename, 04))
 {
-strcpy(sUIStrings.title, "LibreOffice Updater");
-strcpy(sUIStrings.info, "This program is updating your LibreOffice 
installation.");
+strcpy(sUIStrings.title, "LibreOffice Update");
+strcpy(sUIStrings.info, "Please wait while we update your 
installation.");
 return 0;
 }
 
@@ -244,8 +244,8 @@ InitProgressUIStrings()
 // bother showing UI.
 if (ReadStrings(filename, ) != OK)
 {
-strcpy(sUIStrings.title, "LibreOffice Updater");
-strcpy(sUIStrings.info, "This program is updating your LibreOffice 
installation.");
+strcpy(sUIStrings.title, "LibreOffice Update");
+strcpy(sUIStrings.info, "Please wait while we update your 
installation.");
 }
 
 return 0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2018-01-17 Thread Stephan Bergmann
 onlineupdate/source/update/updater/bspatch.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 0b25dc8231b51ef1fdb03274387851d1379a03b5
Author: Stephan Bergmann 
Date:   Wed Jan 17 09:01:18 2018 +0100

Blind fix

...in --enable-online-update=mar code, after
7d8e9d989d0ac4a4055b207726708e9ec0da "convert a

[Libreoffice-commits] core.git: onlineupdate/source

2018-01-15 Thread Stephan Bergmann
 onlineupdate/source/update/updater/bspatch.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 337f8922edbdae7cb3e6659ea6bf3bde9ba8adb0
Author: Stephan Bergmann 
Date:   Tue Jan 16 08:51:10 2018 +0100

Missing include

Change-Id: Id5c7ff8b9d342b557bc87b1ac6f3e2fbc8437d69

diff --git a/onlineupdate/source/update/updater/bspatch.cxx 
b/onlineupdate/source/update/updater/bspatch.cxx
index 10ec56200511..b77d3ea1097b 100644
--- a/onlineupdate/source/update/updater/bspatch.cxx
+++ b/onlineupdate/source/update/updater/bspatch.cxx
@@ -32,6 +32,7 @@
 #include "bspatch.h"
 #include "errors.h"
 
+#include 
 #include 
 #include 
 #include 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-12-30 Thread andreas kainz
 onlineupdate/source/update/updater/updater.png |binary
 onlineupdate/source/update/updater/updater.svg |  650 -
 2 files changed, 1 insertion(+), 649 deletions(-)

New commits:
commit 4ead201c578ce4cc17f65d2a97a591e112307a1a
Author: andreas kainz 
Date:   Sat Dec 30 23:56:13 2017 +0100

Updater Icon: Shrink svg file

Change-Id: I8a45d4e620b1865dda28eb56a89207226eeac9b2
Reviewed-on: https://gerrit.libreoffice.org/47202
Reviewed-by: andreas_kainz 
Tested-by: andreas_kainz 

diff --git a/onlineupdate/source/update/updater/updater.png 
b/onlineupdate/source/update/updater/updater.png
index 030dd60afc37..9d8c6df7789a 100644
Binary files a/onlineupdate/source/update/updater/updater.png and 
b/onlineupdate/source/update/updater/updater.png differ
diff --git a/onlineupdate/source/update/updater/updater.svg 
b/onlineupdate/source/update/updater/updater.svg
index 700294ab9621..6a3e88563283 100644
--- a/onlineupdate/source/update/updater/updater.svg
+++ b/onlineupdate/source/update/updater/updater.svg
@@ -1,649 +1 @@
-
-
-
-http://purl.org/dc/elements/1.1/;
-   xmlns:cc="http://creativecommons.org/ns#;
-   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#;
-   xmlns:svg="http://www.w3.org/2000/svg;
-   xmlns="http://www.w3.org/2000/svg;
-   xmlns:xlink="http://www.w3.org/1999/xlink;
-   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd;
-   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape;
-   width="32"
-   height="32"
-   viewBox="0 0 32 32.01"
-   id="svg6548"
-   version="1.1"
-   inkscape:version="0.91 r13725"
-   sodipodi:docname="updater.svg"
-   inkscape:export-filename="./updater.png"
-   inkscape:export-xdpi="90"
-   inkscape:export-ydpi="90">
-  
-
-  
-  
-
-
-
-  
-  
-
-
-  
-
-
-
-  
-  
-
-
-
-  
-  
-
-
-
-  
-  
-  
-
-
-
-  
-  
-
-
-
-
-
-  
-  
-
-
-
-
-  
-  
-
-
-
-
-
-  
-
-
-
-
-  
-
-
-
-  
-  
-
-  
-  
-
-  
-  
-
-  
-image/svg+xml
-http://purl.org/dc/dcmitype/StillImage; />
-
-  
-
-  
-  
-
-  
-
-
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-
-  
-  
-
-
-  
-  
-  
-  
-
-
-
-  
-  
-  
-  
-
-  
-
-
-  
-
-
-  
-  
-  
-
-  
-
-
-  
-
+http://www.w3.org/2000/svg; 
xmlns:xlink="http://www.w3.org/1999/xlink;>
\ No newline at end of file
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source sccomp/source sc/source sfx2/classification sw/source

2017-11-19 Thread Andrea Gelmini
 onlineupdate/source/update/updater/updater.rc  |2 +-
 sc/source/core/data/drwlayer.cxx   |2 +-
 sccomp/source/solver/DifferentialEvolution.hxx |2 +-
 sfx2/classification/xAL-types.xsd  |4 ++--
 sw/source/core/doc/htmltbl.cxx |2 +-
 sw/source/core/doc/notxtfrm.cxx|2 +-
 sw/source/core/draw/dflyobj.cxx|8 
 sw/source/core/inc/frame.hxx   |8 
 sw/source/filter/ww8/ww8atr.cxx|2 +-
 9 files changed, 16 insertions(+), 16 deletions(-)

New commits:
commit 86b8c063a47c1cca13bc208e17eac0d8d96d9072
Author: Andrea Gelmini 
Date:   Sun Nov 19 21:29:23 2017 +0100

Fix typos

Change-Id: I964528cf4f3b81230c683011e1878b28378b0014
Reviewed-on: https://gerrit.libreoffice.org/44915
Reviewed-by: Julien Nabet 
Tested-by: Julien Nabet 

diff --git a/onlineupdate/source/update/updater/updater.rc 
b/onlineupdate/source/update/updater/updater.rc
index 1628e78933ad..d77cea2fee90 100644
--- a/onlineupdate/source/update/updater/updater.rc
+++ b/onlineupdate/source/update/updater/updater.rc
@@ -53,7 +53,7 @@ IDI_DIALOG ICON ICON_PATH
 
 /
 //
-// Embedded an identifier to uniquely identiy this as a Mozilla updater.
+// Embedded an identifier to uniquely identify this as a Mozilla updater.
 //
 
 STRINGTABLE
diff --git a/sc/source/core/data/drwlayer.cxx b/sc/source/core/data/drwlayer.cxx
index 103093b1741f..7b0cc89fa0f1 100644
--- a/sc/source/core/data/drwlayer.cxx
+++ b/sc/source/core/data/drwlayer.cxx
@@ -896,7 +896,7 @@ void ScDrawLayer::RecalcPos( SdrObject* pObj, 
ScDrawObjData& rData, bool bNegati
 // resize/position the shape to *full* size e.g. how it would be ( 
if no hidden rows/cols affected things )
 pObj->SetLogicRect(aFullRect);
 
-// Ok, here is more nastyness, from xml the Anchor is in terms of 
the LogicRect which is the
+// Ok, here is more nastiness, from xml the Anchor is in terms of 
the LogicRect which is the
 // untransformed unrotated shape, here we swap out that initial 
anchor and from now on use
 // an Anchor based on the SnapRect ( which is what you see on the 
screen )
 ScDrawLayer::GetCellAnchorFromPosition( *pObj, rData, *pDoc, 
nTab1, false, false );
diff --git a/sccomp/source/solver/DifferentialEvolution.hxx 
b/sccomp/source/solver/DifferentialEvolution.hxx
index 7d37ef82b9f8..2ced9b9d209e 100644
--- a/sccomp/source/solver/DifferentialEvolution.hxx
+++ b/sccomp/source/solver/DifferentialEvolution.hxx
@@ -97,7 +97,7 @@ public:
 size_t x = agentIndex; // randomPopulation(generator);
 size_t a, b, c;
 
-// create a copy of choosen random agent in population
+// create a copy of chosen random agent in population
 Individual& rOriginal = maPopulation[x];
 Individual aCandidate(rOriginal);
 
diff --git a/sfx2/classification/xAL-types.xsd 
b/sfx2/classification/xAL-types.xsd
index a91314a87c42..0522990072dc 100644
--- a/sfx2/classification/xAL-types.xsd
+++ b/sfx2/classification/xAL-types.xsd
@@ -51,13 +51,13 @@



-   A list of types of address 
identiifers 
+   A list of types of address 
identifiers 





-   A list of ypes of address line., e.g. 
street details, locality details
+   A list of types of address line, e.g. 
street details, locality details



diff --git a/sw/source/core/doc/htmltbl.cxx b/sw/source/core/doc/htmltbl.cxx
index db087caff864..9408d76aa681 100644
--- a/sw/source/core/doc/htmltbl.cxx
+++ b/sw/source/core/doc/htmltbl.cxx
@@ -1763,7 +1763,7 @@ bool SwHTMLTableLayout::Resize( sal_uInt16 nAbsAvail, 
bool bRecalc,
 }
 
 // Optimisation:
-// If the minimums or maximums should not be recalculated and
+// If the minimum or maximum should not be recalculated and
 // - the table's width never needs to be recalculated, or
 // - the table was already calculated for the passed width, or
 // - the available space is less or equal to the minimum width
diff --git a/sw/source/core/doc/notxtfrm.cxx b/sw/source/core/doc/notxtfrm.cxx
index 1ebb9aaf0944..1ff730d580fb 100644
--- a/sw/source/core/doc/notxtfrm.cxx
+++ b/sw/source/core/doc/notxtfrm.cxx
@@ -1010,7 +1010,7 @@ void paintGraphicUsingPrimitivesHelper(
 // need to use that. Usually the renderer would be a VCL-based
 // PrimitiveRenderer, but there are system-specific shortcuts that
 // will *not* use the VCL-Paint of Bitmap and thus ignore this.
-// Anyways, indirectly using a CLipRegion set at the taget 

[Libreoffice-commits] core.git: onlineupdate/source

2017-09-13 Thread Michael Stahl
 onlineupdate/source/libmar/tool/mar.c  |1 +
 onlineupdate/source/update/updater/updater.cxx |2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 7af14994b58e8d81cb6bdfc5ffd444f564d4355b
Author: Michael Stahl 
Date:   Wed Sep 13 20:44:42 2017 +0200

onlineupdate: work around GCC7 -Werror=implicit-fallthrough

This is pretty stupid, but oh well...

Change-Id: I1e605b2858a917f61922df757809a2aceb14a914

diff --git a/onlineupdate/source/libmar/tool/mar.c 
b/onlineupdate/source/libmar/tool/mar.c
index d67935bd559d..3db3bb86e431 100644
--- a/onlineupdate/source/libmar/tool/mar.c
+++ b/onlineupdate/source/libmar/tool/mar.c
@@ -327,6 +327,7 @@ int main(int argc, char **argv) {
 printf("\n");
 /* The fall through from 'T' to 't' is intentional */
   }
+  /* Fall through */
   case 't':
 return mar_test(argv[2]);
 
diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index 1509d570ba23..53bdc71fbd22 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -4234,7 +4234,7 @@ int add_dir_entries(const NS_tchar *dirpath, ActionList 
*list)
 case FTS_DEFAULT:
 LOG(("add_dir_entries: found a non-standard file: " LOG_S,
  ftsdirEntry->fts_path));
-// Fall through and try to remove as a file
+/* Fall through */ // and try to remove as a file
 
 // Files
 case FTS_F:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-08-29 Thread Markus Mohrhard
 onlineupdate/source/update/updater/progressui_gtk_icon.h |  454 ++-
 1 file changed, 200 insertions(+), 254 deletions(-)

New commits:
commit 663b0a92dc845191b7a7e01856d4b5bee3e0e404
Author: Markus Mohrhard 
Date:   Tue Aug 29 14:58:48 2017 +0200

update the gtk updater icon with the new updater icon

Change-Id: I658a1ec54e74fe57efcaec873991d66be7ba31c1

diff --git a/onlineupdate/source/update/updater/progressui_gtk_icon.h 
b/onlineupdate/source/update/updater/progressui_gtk_icon.h
index de6d0962b9df..6660c071f0b1 100644
--- a/onlineupdate/source/update/updater/progressui_gtk_icon.h
+++ b/onlineupdate/source/update/updater/progressui_gtk_icon.h
@@ -1,259 +1,205 @@
 /* XPM */
 static const char *icon_data[] = {
 /* columns rows colors chars-per-pixel */
-"48 48 205 2 ",
-"   c #191919",
-".  c gray12",
-"X  c #22",
-"o  c gray14",
-"O  c #272727",
-"+  c gray16",
-"@  c #2A2A2A",
-"#  c gray18",
-"$  c #2F2F2F",
-"%  c #313131",
-"&  c #323232",
-"*  c gray20",
-"=  c #343434",
-"-  c #353535",
-";  c gray21",
-":  c #373737",
-">  c gray22",
-",  c #393939",
-"<  c #3A3A3A",
-"1  c gray23",
-"2  c #3C3C3C",
-"3  c gray24",
-"4  c #3E3E3E",
-"5  c #3F3F3F",
-"6  c gray25",
-"7  c #414141",
-"8  c gray26",
-"9  c #434343",
-"0  c #44",
-"q  c gray27",
-"w  c #464646",
-"e  c gray28",
-"r  c #484848",
-"t  c #494949",
-"y  c gray29",
-"u  c #4B4B4B",
-"i  c #4C4C4C",
-"p  c gray30",
-"a  c #4E4E4E",
-"s  c gray31",
-"d  c #505050",
-"f  c #515151",
-"g  c gray32",
-"h  c #535353",
-"j  c gray33",
-"k  c #55",
-"l  c #565656",
-"z  c gray34",
-"x  c #585858",
-"c  c gray35",
-"v  c #5A5A5A",
-"b  c #5B5B5B",
-"n  c gray36",
-"m  c #5D5D5D",
-"M  c gray37",
-"N  c #5F5F5F",
-"B  c #606060",
-"V  c gray38",
-"C  c #626262",
-"Z  c gray39",
-"A  c #646464",
-"S  c #656565",
-"D  c gray40",
-"F  c #676767",
-"G  c #686868",
-"H  c DimGray",
-"J  c #6A6A6A",
-"K  c gray42",
-"L  c #6C6C6C",
-"P  c #6D6D6D",
-"I  c gray43",
-"U  c #6F6F6F",
-"Y  c gray44",
-"T  c #717171",
-"R  c #727272",
-"E  c gray45",
-"W  c #747474",
-"Q  c gray46",
-"!  c #767676",
-"~  c #77",
-"^  c gray47",
-"/  c #797979",
-"(  c gray48",
-")  c #7B7B7B",
-"_  c #7C7C7C",
-"`  c gray49",
-"'  c #7E7E7E",
-"]  c gray50",
-"[  c #808080",
-"{  c #818181",
-"}  c gray51",
-"|  c #838383",
-" . c #848484",
-".. c gray52",
-"X. c #868686",
-"o. c gray53",
-"O. c #88",
-"+. c #898989",
-"@. c gray54",
-"#. c #8B8B8B",
-"$. c gray55",
-"%. c #8D8D8D",
-"&. c #8E8E8E",
-"*. c gray56",
-"=. c #909090",
-"-. c gray57",
-";. c #929292",
-":. c #939393",
-">. c gray58",
-",. c #959595",
-"<. c gray59",
-"1. c #979797",
-"2. c #989898",
-"3. c gray60",
-"4. c #9A9A9A",
-"5. c #9B9B9B",
-"6. c gray61",
-"7. c #9D9D9D",
-"8. c gray62",
-"9. c #9F9F9F",
-"0. c #A0A0A0",
-"q. c gray63",
-"w. c #A2A2A2",
-"e. c gray64",
-"r. c #A4A4A4",
-"t. c #A5A5A5",
-"y. c gray65",
-"u. c #A7A7A7",
-"i. c gray66",
-"p. c #A9A9A9",
-"a. c #AA",
-"s. c gray67",
-"d. c #ACACAC",
-"f. c gray68",
-"g. c #AEAEAE",
-"h. c #AFAFAF",
-"j. c gray69",
-"k. c #B1B1B1",
-"l. c #B2B2B2",
-"z. c gray70",
-"x. c #B4B4B4",
-"c. c gray71",
-"v. c #B6B6B6",
-"b. c #B7B7B7",
-"n. c gray72",
-"m. c #B9B9B9",
-"M. c gray73",
-"N. c #BB",
-"B. c #BCBCBC",
-"V. c gray74",
-"C. c gray",
-"Z. c gray75",
-"A. c #C0C0C0",
-"S. c #C1C1C1",
-"D. c gray76",
-"F. c #C3C3C3",
-"G. c gray77",
-"H. c #C5C5C5",
-"J. c #C6C6C6",
-"K. c gray78",
-"L. c #C8C8C8",
-"P. c gray79",
-"I. c #CACACA",
-"U. c #CBCBCB",
-"Y. c gray80",
-"T. c #CDCDCD",
-"R. c #CECECE",
-"E. c gray81",
-"W. c #D0D0D0",
-"Q. c gray82",
-"!. c #D2D2D2",
-"~. c LightGray",
-"^. c gray83",
-"/. c #D5D5D5",
-"(. c gray84",
-"). c #D7D7D7",
-"_. c #D8D8D8",
-"`. c gray85",
-"'. c #DADADA",
-"]. c gray86",
-"[. c gainsboro",
-"{. c #DD",
-"}. c gray87",
-"|. c #DFDFDF",
-" X c gray88",
-".X c #E1E1E1",
-"XX c #E2E2E2",
-"oX c gray89",
-"OX c #E4E4E4",
-"+X c gray90",
-"@X c #E7E7E7",
-"#X c gray91",
-"$X c #E9E9E9",
-"%X c gray92",
-" c #ECECEC",
-"*X c gray93",
-"=X c #EE",
-"-X c #EFEFEF",
-";X c gray94",
-":X c #F1F1F1",
-">X c #F4F4F4",
-",X c gray96",
-"  c #AB7A2B",
+",  c #A77A34",
+"<  c #A97C33",
+"1  c #8D7751",
+"2  c #8D7A57",
+"3  c #8A7658",
+"4  c #A17D42",
+"5  c #8E7E63",
+"6  c #AE823B",
+"7  c #B88635",
+"8  c #B2853B",
+"9  c #BB8A3A",
+"0  c #C08B36",
+"q  c #AA864A",
+"w  c #AF894D",
+"e  c #BC8D42",
+"r  c #AA8B57",
+"t  c #B38F56",
+"y  c #B79256",
+"u  c #968468",
+"i  c #958A73",
+"p  c #9B8970",
+"a  c #938D7D",
+"s  c #9D927A",
+"d  c #A3916F",
+"f  c #AD966D",
+"g  c #B1996D",
+"h  c #BF9F6E",
+"j  c #A89473",
+"k  c #B59D75",
+"l  c #BEA375",
+"z  c #C08F42",
+"x  c #D29E4B",
+"c  c #C69C5C",
+"v  c #DBA44D",
+"b  c #D5A351",
+"n  c #DCA651",
+"m  c #DFAA56",
+"M  c #D8A75A",
+"N  c #DCAA5B",
+"B  c #C79E60",
+"V  c #C09F6E",
+"C  c #C8A162",
+"Z  c #CCA66A",
+"A  c #DEAE62",
+"S  c #D6AD6E",
+"D  c #DEB16A",
+"F  c 

[Libreoffice-commits] core.git: onlineupdate/source

2017-08-28 Thread andreas kainz
 onlineupdate/source/update/updater/updater.ico |binary
 onlineupdate/source/update/updater/updater.png |binary
 onlineupdate/source/update/updater/updater.svg |  649 +
 3 files changed, 649 insertions(+)

New commits:
commit c220f42d4d91a8903ceec302d718b5f30365e98e
Author: andreas kainz 
Date:   Mon Aug 28 22:40:25 2017 +0200

update updater icon

Change-Id: Ie4f38a51e87f29c322ba5aac2a2ad705bae42e71
Reviewed-on: https://gerrit.libreoffice.org/41660
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/onlineupdate/source/update/updater/updater.ico 
b/onlineupdate/source/update/updater/updater.ico
index 48457029d6aa..7b20ba3ec3ce 100644
Binary files a/onlineupdate/source/update/updater/updater.ico and 
b/onlineupdate/source/update/updater/updater.ico differ
diff --git a/onlineupdate/source/update/updater/updater.png 
b/onlineupdate/source/update/updater/updater.png
index 7b5e78907785..030dd60afc37 100644
Binary files a/onlineupdate/source/update/updater/updater.png and 
b/onlineupdate/source/update/updater/updater.png differ
diff --git a/onlineupdate/source/update/updater/updater.svg 
b/onlineupdate/source/update/updater/updater.svg
new file mode 100644
index ..700294ab9621
--- /dev/null
+++ b/onlineupdate/source/update/updater/updater.svg
@@ -0,0 +1,649 @@
+
+
+
+http://purl.org/dc/elements/1.1/;
+   xmlns:cc="http://creativecommons.org/ns#;
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#;
+   xmlns:svg="http://www.w3.org/2000/svg;
+   xmlns="http://www.w3.org/2000/svg;
+   xmlns:xlink="http://www.w3.org/1999/xlink;
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd;
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape;
+   width="32"
+   height="32"
+   viewBox="0 0 32 32.01"
+   id="svg6548"
+   version="1.1"
+   inkscape:version="0.91 r13725"
+   sodipodi:docname="updater.svg"
+   inkscape:export-filename="./updater.png"
+   inkscape:export-xdpi="90"
+   inkscape:export-ydpi="90">
+  
+
+  
+  
+
+
+
+  
+  
+
+
+  
+
+
+
+  
+  
+
+
+
+  
+  
+
+
+
+  
+  
+  
+
+
+
+  
+  
+
+
+
+
+
+  
+  
+
+
+
+
+  
+  
+
+
+
+
+
+  
+
+
+
+
+  
+
+
+
+  
+  
+
+  
+  
+
+  
+  
+
+  
+image/svg+xml
+http://purl.org/dc/dcmitype/StillImage; />
+
+  
+
+  
+  
+
+  
+
+
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+  
+
+  
+  
+
+
+  
+  
+  
+  
+
+
+
+  
+  
+  
+  
+
+  
+
+
+  
+
+
+  
+  
+  
+
+  
+
+
+  
+
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-08-22 Thread Markus Mohrhard
 onlineupdate/source/update/updater/progressui_gtk.cxx|5 
 onlineupdate/source/update/updater/progressui_gtk_icon.h |  259 +++
 2 files changed, 261 insertions(+), 3 deletions(-)

New commits:
commit b622db74f0dcb32cb1d64f1ad1a365bd45106443
Author: Markus Mohrhard 
Date:   Tue Aug 22 20:30:20 2017 +0200

updater: store the updater GUI icon on linux in the code

The content can be created through convert from the png version.

Change-Id: Icc07a118dfa139f270232a1e708e6907ad02ddea

diff --git a/onlineupdate/source/update/updater/progressui_gtk.cxx 
b/onlineupdate/source/update/updater/progressui_gtk.cxx
index 595a29ad68cf..64d8b18d70ba 100644
--- a/onlineupdate/source/update/updater/progressui_gtk.cxx
+++ b/onlineupdate/source/update/updater/progressui_gtk.cxx
@@ -12,6 +12,7 @@
 #include "readstrings.h"
 #include "errors.h"
 #include 
+#include "progressui_gtk_icon.h"
 
 #define TIMER_INTERVAL 100
 
@@ -87,8 +88,6 @@ ShowProgressUI()
 return -1;
 
 static GdkPixbuf *pixbuf;
-char icon_path[PATH_MAX];
-snprintf(icon_path, sizeof(icon_path), "%s.png", sProgramPath);
 
 g_signal_connect(G_OBJECT(sWin), "delete_event",
  G_CALLBACK(OnDeleteEvent), nullptr);
@@ -99,7 +98,7 @@ ShowProgressUI()
 gtk_window_set_resizable(GTK_WINDOW(sWin), FALSE);
 gtk_window_set_decorated(GTK_WINDOW(sWin), TRUE);
 gtk_window_set_deletable(GTK_WINDOW(sWin),FALSE);
-pixbuf = gdk_pixbuf_new_from_file (icon_path, nullptr);
+pixbuf = gdk_pixbuf_new_from_xpm_data (icon_data);
 gtk_window_set_icon(GTK_WINDOW(sWin), pixbuf);
 g_object_unref(pixbuf);
 
diff --git a/onlineupdate/source/update/updater/progressui_gtk_icon.h 
b/onlineupdate/source/update/updater/progressui_gtk_icon.h
new file mode 100644
index ..de6d0962b9df
--- /dev/null
+++ b/onlineupdate/source/update/updater/progressui_gtk_icon.h
@@ -0,0 +1,259 @@
+/* XPM */
+static const char *icon_data[] = {
+/* columns rows colors chars-per-pixel */
+"48 48 205 2 ",
+"   c #191919",
+".  c gray12",
+"X  c #22",
+"o  c gray14",
+"O  c #272727",
+"+  c gray16",
+"@  c #2A2A2A",
+"#  c gray18",
+"$  c #2F2F2F",
+"%  c #313131",
+"&  c #323232",
+"*  c gray20",
+"=  c #343434",
+"-  c #353535",
+";  c gray21",
+":  c #373737",
+">  c gray22",
+",  c #393939",
+"<  c #3A3A3A",
+"1  c gray23",
+"2  c #3C3C3C",
+"3  c gray24",
+"4  c #3E3E3E",
+"5  c #3F3F3F",
+"6  c gray25",
+"7  c #414141",
+"8  c gray26",
+"9  c #434343",
+"0  c #44",
+"q  c gray27",
+"w  c #464646",
+"e  c gray28",
+"r  c #484848",
+"t  c #494949",
+"y  c gray29",
+"u  c #4B4B4B",
+"i  c #4C4C4C",
+"p  c gray30",
+"a  c #4E4E4E",
+"s  c gray31",
+"d  c #505050",
+"f  c #515151",
+"g  c gray32",
+"h  c #535353",
+"j  c gray33",
+"k  c #55",
+"l  c #565656",
+"z  c gray34",
+"x  c #585858",
+"c  c gray35",
+"v  c #5A5A5A",
+"b  c #5B5B5B",
+"n  c gray36",
+"m  c #5D5D5D",
+"M  c gray37",
+"N  c #5F5F5F",
+"B  c #606060",
+"V  c gray38",
+"C  c #626262",
+"Z  c gray39",
+"A  c #646464",
+"S  c #656565",
+"D  c gray40",
+"F  c #676767",
+"G  c #686868",
+"H  c DimGray",
+"J  c #6A6A6A",
+"K  c gray42",
+"L  c #6C6C6C",
+"P  c #6D6D6D",
+"I  c gray43",
+"U  c #6F6F6F",
+"Y  c gray44",
+"T  c #717171",
+"R  c #727272",
+"E  c gray45",
+"W  c #747474",
+"Q  c gray46",
+"!  c #767676",
+"~  c #77",
+"^  c gray47",
+"/  c #797979",
+"(  c gray48",
+")  c #7B7B7B",
+"_  c #7C7C7C",
+"`  c gray49",
+"'  c #7E7E7E",
+"]  c gray50",
+"[  c #808080",
+"{  c #818181",
+"}  c gray51",
+"|  c #838383",
+" . c #848484",
+".. c gray52",
+"X. c #868686",
+"o. c gray53",
+"O. c #88",
+"+. c #898989",
+"@. c gray54",
+"#. c #8B8B8B",
+"$. c gray55",
+"%. c #8D8D8D",
+"&. c #8E8E8E",
+"*. c gray56",
+"=. c #909090",
+"-. c gray57",
+";. c #929292",
+":. c #939393",
+">. c gray58",
+",. c #959595",
+"<. c gray59",
+"1. c #979797",
+"2. c #989898",
+"3. c gray60",
+"4. c #9A9A9A",
+"5. c #9B9B9B",
+"6. c gray61",
+"7. c #9D9D9D",
+"8. c gray62",
+"9. c #9F9F9F",
+"0. c #A0A0A0",
+"q. c gray63",
+"w. c #A2A2A2",
+"e. c gray64",
+"r. c #A4A4A4",
+"t. c #A5A5A5",
+"y. c gray65",
+"u. c #A7A7A7",
+"i. c gray66",
+"p. c #A9A9A9",
+"a. c #AA",
+"s. c gray67",
+"d. c #ACACAC",
+"f. c gray68",
+"g. c #AEAEAE",
+"h. c #AFAFAF",
+"j. c gray69",
+"k. c #B1B1B1",
+"l. c #B2B2B2",
+"z. c gray70",
+"x. c #B4B4B4",
+"c. c gray71",
+"v. c #B6B6B6",
+"b. c #B7B7B7",
+"n. c gray72",
+"m. c #B9B9B9",
+"M. c gray73",
+"N. c #BB",
+"B. c #BCBCBC",
+"V. c gray74",
+"C. c gray",
+"Z. c gray75",
+"A. c #C0C0C0",
+"S. c #C1C1C1",
+"D. c gray76",
+"F. c #C3C3C3",
+"G. c gray77",
+"H. c #C5C5C5",
+"J. c #C6C6C6",
+"K. c gray78",
+"L. c #C8C8C8",
+"P. c gray79",
+"I. c #CACACA",
+"U. c #CBCBCB",
+"Y. c gray80",
+"T. c #CDCDCD",
+"R. c #CECECE",
+"E. c gray81",
+"W. c #D0D0D0",
+"Q. c gray82",
+"!. c #D2D2D2",
+"~. c LightGray",
+"^. c gray83",
+"/. c #D5D5D5",
+"(. c gray84",
+"). c #D7D7D7",

[Libreoffice-commits] core.git: onlineupdate/source

2017-08-21 Thread Markus Mohrhard
 onlineupdate/source/update/updater/progressui_win.cxx |   11 ---
 1 file changed, 8 insertions(+), 3 deletions(-)

New commits:
commit 9e159f8b868a95ffe0998fdc8dffbbc171f6037b
Author: Markus Mohrhard 
Date:   Mon Aug 21 08:46:44 2017 +0200

updater: always show the updater UI

Change-Id: I0e1dc86673779966ff247b81852fb2f29655d2b9

diff --git a/onlineupdate/source/update/updater/progressui_win.cxx 
b/onlineupdate/source/update/updater/progressui_win.cxx
index b7ff90acbbbf..24aed2c94247 100644
--- a/onlineupdate/source/update/updater/progressui_win.cxx
+++ b/onlineupdate/source/update/updater/progressui_win.cxx
@@ -228,19 +228,24 @@ InitProgressUIStrings()
 WCHAR filename[MAX_PATH];
 if (!GetStringsFile(filename))
 {
-return -1;
+strcpy(sUIStrings.title, "LibreOffice Updater");
+strcpy(sUIStrings.info, "This program is updating your LibreOffice 
installation.");
+return 0;
 }
 
 if (_waccess(filename, 04))
 {
-return -1;
+strcpy(sUIStrings.title, "LibreOffice Updater");
+strcpy(sUIStrings.info, "This program is updating your LibreOffice 
installation.");
+return 0;
 }
 
 // If the updater.ini doesn't have the required strings, then we should not
 // bother showing UI.
 if (ReadStrings(filename, ) != OK)
 {
-return -1;
+strcpy(sUIStrings.title, "LibreOffice Updater");
+strcpy(sUIStrings.info, "This program is updating your LibreOffice 
installation.");
 }
 
 return 0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-07-31 Thread Markus Mohrhard
 onlineupdate/source/update/updater/gen_cert_header.py |   14 --
 1 file changed, 12 insertions(+), 2 deletions(-)

New commits:
commit c210d7cc092616ecdd1072f1238ec3b619f7387b
Author: Markus Mohrhard 
Date:   Mon Jul 24 23:15:33 2017 +0200

make it easier to debug the generation of certificate data

Change-Id: I86e3c3254cef297c46a8ca377b5ceb36b348e2b3
Reviewed-on: https://gerrit.libreoffice.org/40607
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/onlineupdate/source/update/updater/gen_cert_header.py 
b/onlineupdate/source/update/updater/gen_cert_header.py
index a75af1e295fb..3f3798cfb425 100755
--- a/onlineupdate/source/update/updater/gen_cert_header.py
+++ b/onlineupdate/source/update/updater/gen_cert_header.py
@@ -1,5 +1,7 @@
 #!/usr/bin/env python
 
+from __future__ import print_function
+import os
 import sys
 import binascii
 
@@ -13,6 +15,9 @@ def file_byte_generator(filename):
 block = f.read()
 return block
 
+def eprint(*args, **kwargs):
+print(*args, file=sys.stderr, **kwargs)
+
 def create_header(array_name, in_filename):
 if sys.version_info >= (3,0):
 hexified = ["0x" + binascii.hexlify(bytes([inp])).decode('ascii') for 
inp in file_byte_generator(in_filename)]
@@ -25,8 +30,13 @@ def create_header(array_name, in_filename):
 
 if __name__ == '__main__':
 if len(sys.argv) < 3:
-print('ERROR: usage: gen_cert_header.py array_name update_config_file')
-sys.exit(1);
+eprint('ERROR: usage: gen_cert_header.py array_name 
update_config_file')
+sys.exit(1)
+
+if not os.path.exists(sys.argv[2]):
+eprint('The config file %s does not exist'%(sys.argv[2]))
+sys.exit(1)
+
 config = ConfigParser()
 config.read(sys.argv[2])
 sys.exit(create_header(sys.argv[1], config.get('Updater', 
'certificate-der')))
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-07-31 Thread Markus Mohrhard
 onlineupdate/source/update/updater/updater.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 2539702ff5e7bf6bc5dbdb3f8301196487b9266b
Author: Markus Mohrhard 
Date:   Sun Jun 18 12:45:38 2017 +0200

updater: fix windows build, string issues

Change-Id: I79ff08534dc522ede50cd0c5771576d825977b7c
Reviewed-on: https://gerrit.libreoffice.org/40606
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index eb6452a9f6a0..08aa201cb47e 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -2596,8 +2596,8 @@ GetUpdateFileNames(std::vector& fileNames)
 {
 if (NS_tstrncmp(entry->d_name, NS_T("update"), 6) == 0)
 {
-char *dot = strrchr(entry->d_name, '.');
-if (dot && !strcmp(dot, ".mar"))
+NS_tchar *dot = NS_tstrrchr(entry->d_name, NS_T('.'));
+if (dot && !NS_tstrcmp(dot, NS_T(".mar")))
 {
 NS_tchar updatePath[MAXPATHLEN];
 NS_tsnprintf(updatePath, 
sizeof(updatePath)/sizeof(updatePath[0]),
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-07-28 Thread Markus Mohrhard
 onlineupdate/source/libmar/verify/Makefile.in |9 -
 1 file changed, 9 deletions(-)

New commits:
commit 42277cf8ad6946b9b144a3a54b5eb295188ced72
Author: Markus Mohrhard 
Date:   Thu Jul 27 16:53:57 2017 +0200

updater: remove unnecessary mozilla makefile

Change-Id: Ia0162482841854cc4cb5c2b004bc978809bdf4c2
Reviewed-on: https://gerrit.libreoffice.org/40534
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/onlineupdate/source/libmar/verify/Makefile.in 
b/onlineupdate/source/libmar/verify/Makefile.in
deleted file mode 100644
index 4e2cf88aad57..
--- a/onlineupdate/source/libmar/verify/Makefile.in
+++ /dev/null
@@ -1,9 +0,0 @@
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-include $(topsrcdir)/config/rules.mk
-
-# The intermediate (.ii/.s) files for host and target can have the same name...
-# disable parallel builds
-.NOTPARALLEL:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source sal/osl sc/source vcl/quartz

2017-06-20 Thread Noel Grandin
 onlineupdate/source/update/updater/updater.cxx |4 
 sal/osl/unx/file.cxx   |   13 -
 sal/osl/unx/thread.cxx |9 +++--
 sal/osl/w32/file.cxx   |6 --
 sc/source/filter/starcalc/collect.cxx  |2 --
 vcl/quartz/salgdicommon.cxx|9 +++--
 6 files changed, 6 insertions(+), 37 deletions(-)

New commits:
commit 05f67637fc4f71750dda46fccf0bed5b3fd99233
Author: Noel Grandin 
Date:   Tue Jun 20 08:52:10 2017 +0200

new cannot return nullptr

unless we are using std::nothrow

Change-Id: I3bdd13c8ce18f4e977f18ee5196311bf4fc62de0
Reviewed-on: https://gerrit.libreoffice.org/38998
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index d32e6916cb12..01ca1a2475a9 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -315,10 +315,6 @@ get_full_path(const NS_tchar *relpath)
 size_t lendestpath = NS_tstrlen(destpath);
 size_t lenrelpath = NS_tstrlen(relpath);
 NS_tchar *s = new NS_tchar[lendestpath + lenrelpath + 2];
-if (!s)
-{
-return nullptr;
-}
 
 NS_tchar *c = s;
 
diff --git a/sal/osl/unx/file.cxx b/sal/osl/unx/file.cxx
index 9d7b31d3a7d4..333d2459b351 100644
--- a/sal/osl/unx/file.cxx
+++ b/sal/osl/unx/file.cxx
@@ -734,8 +734,6 @@ oslFileHandle osl::detail::createFileHandleFromFD( int fd )
 return nullptr; // EBADF
 
 FileHandle_Impl * pImpl = new FileHandle_Impl (fd);
-if (pImpl == nullptr)
-return nullptr; // ENOMEM
 
 // assume writeable
 pImpl->m_state |= FileHandle_Impl::STATE_WRITEABLE;
@@ -809,11 +807,6 @@ openMemoryAsFile( void *address, size_t size, 
oslFileHandle *pHandle, const char
 {
 oslFileError eRet;
 FileHandle_Impl * pImpl = new FileHandle_Impl (-1, 
FileHandle_Impl::KIND_MEM, path);
-if (!pImpl)
-{
-eRet = oslTranslateFileError (OSL_FET_ERROR, ENOMEM);
-return eRet;
-}
 pImpl->m_size = sal::static_int_cast< sal_uInt64 >(size);
 
 *pHandle = (oslFileHandle)(pImpl);
@@ -1015,12 +1008,6 @@ openFilePath( const char *cpFilePath, oslFileHandle* 
pHandle, sal_uInt32 uFlags,
 
 /* allocate memory for impl structure */
 FileHandle_Impl * pImpl = new FileHandle_Impl (fd, 
FileHandle_Impl::KIND_FD, cpFilePath);
-if (!pImpl)
-{
-eRet = oslTranslateFileError (OSL_FET_ERROR, ENOMEM);
-(void) close(fd);
-return eRet;
-}
 if (flags & O_RDWR)
 pImpl->m_state |= FileHandle_Impl::STATE_WRITEABLE;
 pImpl->m_size = sal::static_int_cast< sal_uInt64 >(aFileStat.st_size);
diff --git a/sal/osl/unx/thread.cxx b/sal/osl/unx/thread.cxx
index 2fb488a48b57..3e6b36a2c8ca 100644
--- a/sal/osl/unx/thread.cxx
+++ b/sal/osl/unx/thread.cxx
@@ -148,13 +148,10 @@ static void osl_thread_init_Impl()
 Thread_Impl* osl_thread_construct_Impl()
 {
 Thread_Impl* pImpl = new Thread_Impl;
-if (pImpl)
-{
-memset (pImpl, 0, sizeof(Thread_Impl));
+memset (pImpl, 0, sizeof(Thread_Impl));
 
-pthread_mutex_init (&(pImpl->m_Lock), PTHREAD_MUTEXATTR_DEFAULT);
-pthread_cond_init  (&(pImpl->m_Cond), PTHREAD_CONDATTR_DEFAULT);
-}
+pthread_mutex_init (&(pImpl->m_Lock), PTHREAD_MUTEXATTR_DEFAULT);
+pthread_cond_init  (&(pImpl->m_Cond), PTHREAD_CONDATTR_DEFAULT);
 return pImpl;
 }
 
diff --git a/sal/osl/w32/file.cxx b/sal/osl/w32/file.cxx
index d7ef5623cd4e..97f6d8fe6d33 100644
--- a/sal/osl/w32/file.cxx
+++ b/sal/osl/w32/file.cxx
@@ -677,12 +677,6 @@ SAL_CALL osl_createFileHandleFromOSHandle (
 return nullptr; // EINVAL
 
 FileHandle_Impl * pImpl = new FileHandle_Impl(hFile);
-if (pImpl == nullptr)
-{
-// cleanup and fail
-(void) ::CloseHandle(hFile);
-return nullptr; // ENOMEM
-}
 
 /* check for regular file */
 if (FILE_TYPE_DISK == GetFileType(hFile))
diff --git a/sc/source/filter/starcalc/collect.cxx 
b/sc/source/filter/starcalc/collect.cxx
index dbb4c10f63a2..3ed51bfba774 100644
--- a/sc/source/filter/starcalc/collect.cxx
+++ b/sc/source/filter/starcalc/collect.cxx
@@ -78,8 +78,6 @@ bool ScCollection::AtInsert(sal_uInt16 nIndex, ScDataObject* 
pScDataObject)
 if (nCount == nLimit)
 {
 ScDataObject** pNewItems = new ScDataObject*[nLimit + nDelta];
-if (!pNewItems)
-return false;
 nLimit = sal::static_int_cast( nLimit + nDelta );
 memcpy(pNewItems, pItems, nCount * sizeof(ScDataObject*));
 delete[] pItems;
diff --git a/vcl/quartz/salgdicommon.cxx b/vcl/quartz/salgdicommon.cxx
index 2f36c76d4303..73cd294104ce 100644
--- a/vcl/quartz/salgdicommon.cxx
+++ 

[Libreoffice-commits] core.git: onlineupdate/source

2017-06-17 Thread Markus Mohrhard
 onlineupdate/source/update/updater/updater.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 3107c78017767a83505f9d21e3aaddea1e30569d
Author: Markus Mohrhard 
Date:   Sat Jun 17 22:59:42 2017 +0200

-Werror=maybe-uninitialized

Change-Id: Iba942ded86c8e4565bcd14796f05f47e3fc64880

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index e65d9a99c14a..d32e6916cb12 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -2685,7 +2685,7 @@ static void
 UpdateThreadFunc(void * /*param*/)
 {
 // open ZIP archive and process...
-int rv;
+int rv = OK;
 if (sReplaceRequest)
 {
 rv = ProcessReplaceRequest();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source

2017-06-17 Thread Markus Mohrhard
 onlineupdate/source/update/updater/updater.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 4c1d68ca54029660624de7a1ed5043dbbbd9ff18
Author: Markus Mohrhard 
Date:   Sat Jun 17 21:05:20 2017 +0200

updater: fix missing header for std::vector

Change-Id: Ifd71745ce671a673ff3d4e9c2ca7a4abb6bed363

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index 8b3f7bceee8d..e65d9a99c14a 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -40,6 +40,7 @@
 #include "errors.h"
 #include "bzlib.h"
 #include 
+#include 
 
 #include 
 #include 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: onlineupdate/source opencl/inc svtools/source vcl/source

2017-06-04 Thread Jochen Nitschke
 onlineupdate/source/update/updater/updater.cxx |8 
 opencl/inc/opencl_device_selection.h   |2 +-
 svtools/source/contnr/treelist.cxx |4 ++--
 vcl/source/filter/graphicfilter.cxx|8 
 4 files changed, 11 insertions(+), 11 deletions(-)

New commits:
commit 8511ee5cd11a5143a4476c0152f0ede0f2b6b87e
Author: Jochen Nitschke 
Date:   Sun Jun 4 13:43:12 2017 +0200

no need to construct unique_ptr here

and std::move is not needed when returning unique_ptr

Change-Id: I9b4d2d6b8a41b570a9bd99e44a743ff161b78c59
Reviewed-on: https://gerrit.libreoffice.org/38385
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index cd63539edfb4..f1800448087f 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -1134,7 +1134,7 @@ RemoveFile::Parse(NS_tchar *line)
 if (!validPath)
 return PARSE_ERROR;
 
-mRelPath = std::unique_ptr(new NS_tchar[MAXPATHLEN]);
+mRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mRelPath.get(), validPath);
 
 mFile.reset(get_full_path(validPath));
@@ -1261,7 +1261,7 @@ RemoveDir::Parse(NS_tchar *line)
 NS_tchar* validPath = get_valid_path(, true);
 if (!validPath)
 return PARSE_ERROR;
-mRelPath = std::unique_ptr(new NS_tchar[MAXPATHLEN]);
+mRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mRelPath.get(), validPath);
 
 mDir.reset(get_full_path(validPath));
@@ -1386,7 +1386,7 @@ AddFile::Parse(NS_tchar *line)
 if (!validPath)
 return PARSE_ERROR;
 
-mRelPath = std::unique_ptr(new NS_tchar[MAXPATHLEN]);
+mRelPath.reset(new NS_tchar[MAXPATHLEN]);
 
 NS_tstrcpy(mRelPath.get(), validPath);
 
@@ -1582,7 +1582,7 @@ PatchFile::Parse(NS_tchar *line)
 NS_tchar* validPath = get_valid_path();
 if (!validPath)
 return PARSE_ERROR;
-mFileRelPath = std::unique_ptr(new NS_tchar[MAXPATHLEN]);
+mFileRelPath.reset(new NS_tchar[MAXPATHLEN]);
 NS_tstrcpy(mFileRelPath.get(), validPath);
 
 mFile.reset(get_full_path(validPath));
diff --git a/opencl/inc/opencl_device_selection.h 
b/opencl/inc/opencl_device_selection.h
index 3a47ff6d8d5e..79f88894c378 100644
--- a/opencl/inc/opencl_device_selection.h
+++ b/opencl/inc/opencl_device_selection.h
@@ -148,7 +148,7 @@ inline ds_status initDSProfile(std::unique_ptr& 
rProfile, OString co
 unsigned int next;
 unsigned int i;
 
-rProfile = std::unique_ptr(new ds_profile(rVersion));
+rProfile.reset(new ds_profile(rVersion));
 
 clGetPlatformIDs(0, nullptr, );
 if (numPlatforms != 0)
diff --git a/svtools/source/contnr/treelist.cxx 
b/svtools/source/contnr/treelist.cxx
index bd8d55e3a1b6..76fb434aaa6c 100644
--- a/svtools/source/contnr/treelist.cxx
+++ b/svtools/source/contnr/treelist.cxx
@@ -1040,7 +1040,7 @@ bool SvTreeList::Remove( const SvTreeListEntry* pEntry )
 bLastEntry = (nListPos == (rList.size()-1));
 SvTreeListEntries::iterator it = rList.begin();
 std::advance(it, nListPos);
-pEntryDeleter = std::unique_ptr(std::move(*it));
+pEntryDeleter = std::move(*it);
 rList.erase(it);
 }
 else
@@ -1049,7 +1049,7 @@ bool SvTreeList::Remove( const SvTreeListEntry* pEntry )
 std::find_if(rList.begin(), rList.end(), FindByPointer(pEntry));
 if (it != rList.end())
 {
-pEntryDeleter = std::unique_ptr(std::move(*it));
+pEntryDeleter = std::move(*it);
 rList.erase(it);
 }
 }
diff --git a/vcl/source/filter/graphicfilter.cxx 
b/vcl/source/filter/graphicfilter.cxx
index 495d85d6b8c9..e148287038f7 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -1439,7 +1439,7 @@ void GraphicFilter::ImportGraphics(std::vector< 
std::shared_ptr >& rGra
 {
 try
 {
-pGraphicContent =  std::unique_ptr(new 
sal_uInt8[nGraphicContentSize]);
+pGraphicContent.reset(new sal_uInt8[nGraphicContentSize]);
 }
 catch (const std::bad_alloc&)
 {
@@ -1606,7 +1606,7 @@ ErrCode GraphicFilter::ImportGraphic( Graphic& rGraphic, 
const OUString& rPath,
 const std::vector& rData = aIter->aData;
 nGraphicContentSize = nChunkSize - 11;
 SvMemoryStream 
aIStrm(const_cast([11]), nGraphicContentSize, 
StreamMode::READ);
-pGraphicContent = std::unique_ptr(new 
sal_uInt8[nGraphicContentSize]);
+pGraphicContent.reset(new 
sal_uInt8[nGraphicContentSize]);
 

[Libreoffice-commits] core.git: onlineupdate/source

2016-03-31 Thread Michael Stahl
 onlineupdate/source/update/common/uachelper.cxx   |2 
 onlineupdate/source/update/common/updatehelper.cxx|7 -
 onlineupdate/source/update/common/updatelogging.cxx   |4 
 onlineupdate/source/update/updater/loaddlls.cxx   |2 
 onlineupdate/source/update/updater/progressui_win.cxx |4 
 onlineupdate/source/update/updater/updater.cxx|   86 +-
 onlineupdate/source/update/updater/win_dirent.cxx |6 -
 7 files changed, 56 insertions(+), 55 deletions(-)

New commits:
commit 1ab775bdbae1aa148faee2a51f2f4aadae57
Author: Michael Stahl 
Date:   Thu Mar 31 13:07:05 2016 +0200

onlineupdate: revert SAL_N_ELEMENTS changes

It's not clear if the foreign code in onlineupdate is supposed to
include sal headers, so revert the 2 changes from earlier today there.

Change-Id: I604720b4bd4897204e354ec230582b0fd2036716

diff --git a/onlineupdate/source/update/common/uachelper.cxx 
b/onlineupdate/source/update/common/uachelper.cxx
index 6937e00..4cae3ad 100644
--- a/onlineupdate/source/update/common/uachelper.cxx
+++ b/onlineupdate/source/update/common/uachelper.cxx
@@ -191,7 +191,7 @@ BOOL
 UACHelper::DisablePrivileges(HANDLE token)
 {
   static const size_t PrivsToDisableSize =
-SAL_N_ELEMENTS(UACHelper::PrivsToDisable);
+sizeof(UACHelper::PrivsToDisable) / sizeof(UACHelper::PrivsToDisable[0]);
 
   return DisableUnneededPrivileges(token, UACHelper::PrivsToDisable,
PrivsToDisableSize);
diff --git a/onlineupdate/source/update/common/updatehelper.cxx 
b/onlineupdate/source/update/common/updatehelper.cxx
index 704dde8..c10ea8d 100644
--- a/onlineupdate/source/update/common/updatehelper.cxx
+++ b/onlineupdate/source/update/common/updatehelper.cxx
@@ -100,7 +100,7 @@ LaunchWinPostProcess(const WCHAR *installationDir,
 
   if (!GetPrivateProfileStringW(L"PostUpdateWin", L"ExeAsync", L"TRUE",
 exeasync,
-SAL_N_ELEMENTS(exeasync),
+sizeof(exeasync)/sizeof(exeasync[0]),
 inifile)) {
 return FALSE;
   }
@@ -123,7 +123,7 @@ LaunchWinPostProcess(const WCHAR *installationDir,
   }
 
   WCHAR dummyArg[14] = { L'\0' };
-  wcsncpy(dummyArg, L"argv0ignored ", SAL_N_ELEMENTS(dummyArg) - 1);
+  wcsncpy(dummyArg, L"argv0ignored ", sizeof(dummyArg) / sizeof(dummyArg[0]) - 
1);
 
   size_t len = wcslen(exearg) + wcslen(dummyArg);
   WCHAR *cmdline = (WCHAR *) malloc((len + 1) * sizeof(WCHAR));
@@ -266,7 +266,8 @@ StartServiceUpdate(LPCWSTR installDir)
   si.lpDesktop = L"";
   PROCESS_INFORMATION pi = {0};
   WCHAR cmdLine[64] = { '\0' };
-  wcsncpy(cmdLine, L"dummyparam.exe upgrade", SAL_N_ELEMENTS(cmdLine) - 1);
+  wcsncpy(cmdLine, L"dummyparam.exe upgrade",
+  sizeof(cmdLine) / sizeof(cmdLine[0]) - 1);
   BOOL svcUpdateProcessStarted = CreateProcessW(tmpService,
 cmdLine,
 nullptr, nullptr, FALSE,
diff --git a/onlineupdate/source/update/common/updatelogging.cxx 
b/onlineupdate/source/update/common/updatelogging.cxx
index c1ffcb0..22a74e1 100644
--- a/onlineupdate/source/update/common/updatelogging.cxx
+++ b/onlineupdate/source/update/common/updatelogging.cxx
@@ -30,11 +30,11 @@ void UpdateLog::Init(NS_tchar* sourcePathParam,
 
   sourcePath = sourcePathParam;
   NS_tchar logFile[MAXPATHLEN];
-  NS_tsnprintf(logFile, SAL_N_ELEMENTS(logFile),
+  NS_tsnprintf(logFile, sizeof(logFile)/sizeof(logFile[0]),
 NS_T("%s/%s"), sourcePathParam, fileName);
 
   if (alternateFileName && NS_taccess(logFile, F_OK)) {
-NS_tsnprintf(logFile, SAL_N_ELEMENTS(logFile),
+NS_tsnprintf(logFile, sizeof(logFile)/sizeof(logFile[0]),
   NS_T("%s/%s"), sourcePathParam, alternateFileName);
   }
 
diff --git a/onlineupdate/source/update/updater/loaddlls.cxx 
b/onlineupdate/source/update/updater/loaddlls.cxx
index 0ec061d..94a4222 100644
--- a/onlineupdate/source/update/updater/loaddlls.cxx
+++ b/onlineupdate/source/update/updater/loaddlls.cxx
@@ -90,7 +90,7 @@ struct AutoLoadSystemDependencies
 }
 
 // For each known DLL ensure it is loaded from the system32 directory
-for (size_t i = 0; i < SAL_N_ELEMENTS(delayDLLs); ++i) {
+for (size_t i = 0; i < sizeof(delayDLLs) / sizeof(delayDLLs[0]); ++i) {
   size_t fileLen = wcslen(delayDLLs[i]);
   wcsncpy(systemDirectory + systemDirLen, delayDLLs[i],
   MAX_PATH - systemDirLen);
diff --git a/onlineupdate/source/update/updater/progressui_win.cxx 
b/onlineupdate/source/update/updater/progressui_win.cxx
index cdef03f..7a0ff24 100644
--- a/onlineupdate/source/update/updater/progressui_win.cxx
+++ b/onlineupdate/source/update/updater/progressui_win.cxx
@@ -111,9 +111,9 @@ InitDialog(HWND hDlg)
   WCHAR szwInfo[MAX_TEXT_LEN];
 
   MultiByteToWideChar(CP_UTF8, 0, sUIStrings.title, -1, szwTitle,
-