1 страниц (8 вхождений)
Crash on saving - Improper saving when opening files from forum - Сообщения
#1 Опубликовано: 20.02.2018 05:33:48
Hello to Everybody,
I just noted a strange behaviour of Smath, I am using release 99.6622 but I believe it is the same in other versions.
If you open a file on the fly (without downloading) from an external source (i.e.: Smath Forum) and then you make any change to it, when you close the file you are prompted with a request to save the file.
If you (improperly) answer "Yes", Smath crashes.
I think Smath is right in the sense that you shouldn't save to a read-only location, but for the sake of completeness, you might want to protect against improper use from inexperienced users...
Thanks for the attention
Marco
I just noted a strange behaviour of Smath, I am using release 99.6622 but I believe it is the same in other versions.
If you open a file on the fly (without downloading) from an external source (i.e.: Smath Forum) and then you make any change to it, when you close the file you are prompted with a request to save the file.
If you (improperly) answer "Yes", Smath crashes.
I think Smath is right in the sense that you shouldn't save to a read-only location, but for the sake of completeness, you might want to protect against improper use from inexperienced users...

Thanks for the attention
Marco
#2 Опубликовано: 20.02.2018 06:30:46
Grazie Marco 
Bug confirmed (unhandled System.UnauthorizedAccessException).
Guess the right way is:
1) check for permissions
2) If permissions are denied, prompt the "save as" dialog;

Bug confirmed (unhandled System.UnauthorizedAccessException).
Guess the right way is:
1) check for permissions
2) If permissions are denied, prompt the "save as" dialog;
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#3 Опубликовано: 21.02.2018 03:51:39
Hello, Davide.
I've made some improvements to saving logic. Please could you check the same scenario with latest sources?
Unfortunately I'm unable to reproduce this issue.
Thanks in advance!
I've made some improvements to saving logic. Please could you check the same scenario with latest sources?
Unfortunately I'm unable to reproduce this issue.
Thanks in advance!
#4 Опубликовано: 21.02.2018 04:50:57
Hello Andrey,
Not fixed with your improvements. To reproduce simply mark a file as readonly from the system file properties before opening it with SS.
In my sandbox folder there is a possible solution
Not fixed with your improvements. To reproduce simply mark a file as readonly from the system file properties before opening it with SS.
In my sandbox folder there is a possible solution

If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 пользователям понравился этот пост
Andrey Ivashov 21.02.2018 16:29:00
#5 Опубликовано: 21.02.2018 12:01:26
WroteHello to Everybody,
I just noted a strange behaviour of Smath, I am using release 99.6622 but I believe it is the same in other versions.
If you open a file on the fly (without downloading) from an external source (i.e.: Smath Forum) and then you make any change to it, when you close the file you are prompted with a request to save the file.
If you (improperly) answer "Yes", Smath crashes.
I think Smath is right in the sense that you shouldn't save to a read-only location, but for the sake of completeness, you might want to protect against improper use from inexperienced users...
Thanks for the attention
Marco
Hello Marco,
Superb description, the missing link is that if you save from open on the fly,
good thing Smath crashes ... What ! Yes What, how Smath knows where to save ?
Back to originator ... no way. Why not Save as ...
Have you tried copy/paste on new sheet => Save as in some addressed location ?
Jean
#6 Опубликовано: 21.02.2018 15:15:13
WroteYes What, how Smath knows where to save ?
Back to originator ... no way. Why not Save as ...
This is not a big deal, the file downloaded for reading is stored in a temporary path and flushed when you close the browser, Smath knows the path and since is a temp folder can write in it

If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#7 Опубликовано: 21.02.2018 15:31:34
Thank you very much Davide!
I've taken your fix as a basis and extended it to support all possible places where saving to file may be called (i.e. desktop UI, silent mode, etc.). So, this is done now.
Best regards.
I've taken your fix as a basis and extended it to support all possible places where saving to file may be called (i.e. desktop UI, silent mode, etc.). So, this is done now.
Best regards.
1 пользователям понравился этот пост
Davide Carpi 21.02.2018 15:33:00
#8 Опубликовано: 21.02.2018 16:29:06
FYI: Fix is a part of just released nightly build: https://en.smath.info/forum/yaf_postst12549_SMath-Studio-0-99-6626--21-February-2018.aspx
1 пользователям понравился этот пост
Davide Carpi 22.02.2018 20:39:00
1 страниц (8 вхождений)
-
Новые сообщения
-
Нет новых сообщений