pyuno/source/module/pyuno_type.cxx | 4 ++++ 1 file changed, 4 insertions(+)
New commits: commit 485ec8e14306352f44056bcb644bb4cacdb6490a Author: Noel Grandin <noel.gran...@collabora.co.uk> AuthorDate: Wed Oct 31 13:31:55 2018 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Thu Nov 1 06:43:41 2018 +0100 fix pyuno compile on Fedora29 'PyUnicode_GetSize' is deprecated [-Werror,-Wdeprecated-declarations] Change-Id: Id298d6a2b0af9ce418f9124c9addda55fcdc0318 Reviewed-on: https://gerrit.libreoffice.org/62687 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/pyuno/source/module/pyuno_type.cxx b/pyuno/source/module/pyuno_type.cxx index 80505d85bbd1..fc6385e2be1b 100644 --- a/pyuno/source/module/pyuno_type.cxx +++ b/pyuno/source/module/pyuno_type.cxx @@ -135,7 +135,11 @@ sal_Unicode PyChar2Unicode( PyObject *obj ) "attribute value of uno.Char is not a unicode string" ); } +#if PY_MAJOR_VERSION == 3 && PY_MINOR_VERSION >= 3 + if( PyUnicode_GetLength( value.get() ) < 1 ) +#else if( PyUnicode_GetSize( value.get() ) < 1 ) +#endif { throw RuntimeException( "uno.Char contains an empty unicode string"); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits