[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-4' - loleaflet/src

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Fri May 3 14:19:30 UTC 2019


 loleaflet/src/control/Control.LokDialog.js |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 64afe9328ed619a3d5c8da941099a435d253020e
Author:     Henry Castro <hcastro at collabora.com>
AuthorDate: Wed Apr 24 00:31:08 2019 -0400
Commit:     Henry Castro <hcastro at collabora.com>
CommitDate: Fri May 3 16:19:12 2019 +0200

    loleaflet: validate that the rectangle coordinates (x, y) belongs to ZxZ
    
    Change-Id: Ibbb1cf1416ec441f1e3d4baaf6fdf6f47ab6041c
    Reviewed-on: https://gerrit.libreoffice.org/71150
    Reviewed-by: Henry Castro <hcastro at collabora.com>
    Tested-by: Henry Castro <hcastro at collabora.com>
    Reviewed-on: https://gerrit.libreoffice.org/71244

diff --git a/loleaflet/src/control/Control.LokDialog.js b/loleaflet/src/control/Control.LokDialog.js
index e151ff820..f55438827 100644
--- a/loleaflet/src/control/Control.LokDialog.js
+++ b/loleaflet/src/control/Control.LokDialog.js
@@ -195,7 +195,7 @@ L.Control.LokDialog = L.Control.extend({
 
 	_isRectangleValid: function(rect) {
 		rect = rect.split(',');
-		return (parseInt(rect[0]) >= 0 && parseInt(rect[1]) >= 0 &&
+		return (!isNaN(rect[0]) && !isNaN(rect[1]) &&
 				parseInt(rect[2]) >= 0 && parseInt(rect[3]) >= 0);
 	},
 


More information about the Libreoffice-commits mailing list