14 Replies Latest reply on Jun 29, 2015 6:29 AM by TSGal

    FM Pro 14 - Crash - Division by zero

    DD_1

      Summary

      FM Pro 14 - Crash - Division by zero

      Product

      FileMaker Pro

      Version

      14.0.1.175

      Operating system version

      Windows 7 Professional SP1

      Description of the issue

      Sometimes when users execute scripts that create records, a division by zero crash occurs in FileMaker Pro or Advanced. The script that crashes the user does not always do so and may execute fine the next attempt. The record is created and it looks as if the script completed it's task. No observed database corruption, all files verify with no error. Solution is hosted on FileMaker Server.

      Steps to reproduce the problem

      Cannot reliably reproduce, it is fairly random, but seems to mostly occur in scripts that create records.

      Expected result

      Script executes, creates record, script completes.

      Actual result

      Application crash and divide by zero crash dump file created.

      Exact text of any error message(s) that appear

      Application crash window appears. Portion of crash dump file below:


      Dump Summary
      ------------
      Dump File:     FileMaker Pro Advanced.exe.10596.dmp : C:\Users\\AppData\Local\CrashDumps\FileMaker Pro Advanced.exe.10596.dmp
      Last Write Time:     5/27/2015 3:38:12 PM
      Process Name:     FileMaker Pro Advanced.exe : C:\Program Files (x86)\FileMaker\FileMaker Pro 14 Advanced\FileMaker Pro Advanced.exe
      Process Architecture:     x86
      Exception Code:     0xC0000094
      Exception Information:     The thread tried to divide an integer value by an integer divisor of zero.
      Heap Information:     Not Present

      System Information
      ------------------
      OS Version:     6.1.7601
      CLR Version(s):     4.0.30319.18444

      Workaround

      I was forced to revert to FM13v9 for users.

        • 1. Re: FM Pro 14 - Crash - Division by zero
          TSGal

          DD:

          Thank you for your post.

          Does the crash occur running the same script?  Or, does it occur when running any script that creates a record?

          What other script steps are used with those scripts?

          Do you have any Auto-Enter options in the table where the records are added?  Any calculations?

          Do you have any plug-ins installed and enabled?

          Anything else you can provide may be helpful in narrowing down the possible causes.

          TSGal
          FileMaker, Inc.

          • 2. Re: FM Pro 14 - Crash - Division by zero
            DD_1

            Does the crash occur running the same script?  Or, does it occur when running any script that creates a record?

                   
            • Two script events can be confirmed to crash occasionally. I can't say for sure. The scripts that do end up crashing involve a record duplication or creation either in same table or via relationship.

            What other script steps are used with those scripts?

                   
            • Set field
            •      
            • Commit records
            •      
            • Show/Hide Toolbars
            •      
            • Adjust Window
            •      
            • Refresh Window
            •      
            • Revert record
            •      
            • Freeze window
            •      
            • Go to layout
            •      
            • Show custom dialogue
            •      
            • Duplicate record
            •      
            • Set variable
            •      
            • Perform script (current and other file) (with and without script parameter)
            •      
            • Go to related record (external)

            Do you have any Auto-Enter options in the table where the records are added?  Any calculations?

                   
            • Yes and Yes. One calculation could result in a division by zero. Usually this is handled with a '?' result.

            Do you have any plug-ins installed and enabled?

                   
            • None on clients. 32-bit client is used.

            Anything else you can provide may be helpful in narrowing down the possible causes.

                   
            • Classic layout is used.
            • 3. Re: FM Pro 14 - Crash - Division by zero
              TSGal

              DD:

              Thank you for the additional information.

              Whenever you have a calculation that divides by zero, you could run into some issues.  Therefore, try changing the calculation that possibly divides by 0.  That is, create an If () function that checks the denominator for 0, and if true, either make the result 0 (zero) or blank.  That would leave the Else portion with your current calculation.  Let me know if this stops the crashing.

              TSGal
              FileMaker, Inc.

              • 4. Re: FM Pro 14 - Crash - Division by zero
                philmodjunk

                But division by zero should NEVER crash the FileMaker application even though it may produce a ? or other undesired value.

                • 5. Re: FM Pro 14 - Crash - Division by zero
                  TSGal

                  PhilModJunk:

                  That is correct.  Division by zero should never crash FileMaker Pro.  However, since FileMaker Pro 14 has been released for less than a month, I'm trying to determine if this is a contributing factor to the crash.

                  TSGal
                  FileMaker, Inc.

                  • 6. Re: FM Pro 14 - Crash - Division by zero
                    DD_1

                    I added checks for division by zero in the offending calculations. It will take some time to get reliable reports. 

                     

                    Not to derail, perhaps related in some way, but I did notice two other crashes while working on this:

                           
                    1. Crash when adding a field to database table. Access Violation. Field was still added to the database.
                    2.      
                    3. One database file's layouts were all white. No script running. Changing views, layout, or using refresh window did not help, still completely white. I closed the file and then while reopening it crashed. Access Violation. The file worked fine the next attempt to open.

                    Both crash dumps say:

                    Exception Code:    0xC0000005
                    Exception Information:    The thread tried to read from or write to a virtual address for which it does not have the appropriate access.

                    • 7. Re: FM Pro 14 - Crash - Division by zero
                      TSGal

                      DD:

                      Thank you for the additional information.

                      It appears you may have a damaged file.  Try running a Recover on the database file (from the File menu).  When the Recover finishes, open the recovered file and see if a crash occurs.

                      TSGal
                      FileMaker, Inc.

                      • 8. Re: FM Pro 14 - Crash - Division by zero
                        DD_1

                        Timestamp    Filename    Error    Message
                        2015-06-08 15:08:11.118 -0700    <filename>.fmp12    0    *** Started consistency check, total of 118450 block(s) to check
                        2015-06-08 15:11:44.261 -0700    <filename>.fmp12    0    *** Completed consistency check, checked 118450 block(s)

                        --------------------------------------------------

                        2015-06-08 15:23:59.910 -0700    <filename>.fmp12    0    File blocks: scanned and rebuilt 117955 block(s), dropped 0 invalid data block(s)
                        2015-06-08 15:23:59.912 -0700    <filename>.fmp12    0    Schema: scanned fields and tables; no problems found
                        2015-06-08 15:23:59.913 -0700    <filename>.fmp12    0    Structure: scanned; 0 item(s) modified
                        2015-06-08 15:23:59.914 -0700    <filename>.fmp12    0    File size after recovery is 485412864 bytes
                        2015-06-08 15:23:59.916 -0700    <filename>.fmp12    0    *** Completed recovery to '<filename> Recovered.fmp12'

                        Is there another way to tell if there is actual damage? The recover log on a copy of the file didn't really say anything profound. These databases work fine with the 13v9 client. Red herring?

                        • 9. Re: FM Pro 14 - Crash - Division by zero
                          TSGal

                          DD:

                          Thanks for the additional information.

                          Since the file crashes in FileMaker Pro 14.0.1 but not FileMaker Pro 13.0v9, send in a copy/clone of the file so our Testing department can work with the file directly to find the cause.  In addition, please also send in the crash .dmp file.  Check your Inbox at the top of this page for instructions where to send the files.

                          TSGal
                          FileMaker, Inc.

                          • 10. Re: FM Pro 14 - Crash - Division by zero
                            DD_1

                            I sent the crash dumps using the instructions provided.

                            Crashes still persist after the change to calculation fields that could result in division by zero "?" result.

                            • 11. Re: FM Pro 14 - Crash - Division by zero
                              TSGal

                              DD:

                              Confirming that the files have been received.  Thank you.

                              Without the database file, it may be difficult to determine what is causing the crash.  Regardless, I have sent the .dmp files to Development and Testing for review.  When I receive any feedback, I will let you know.

                              TSGal
                              FileMaker, Inc.

                              • 12. Re: FM Pro 14 - Crash - Division by zero
                                DD_1

                                Thank you, TSGal. 

                                Revisiting your previous suggestion, I ran recovery on other files than the one that had the "white layouts" issue. I found a few files with a couple errors and after following best practices for recovery to no avail, I was forced to use the recovered files, even though recovery explicitly says not to. There is no "good" backup of any file, even going years back. All contain the same errors. The files may have inherited the damage since the FM7 days. The few fixes I saw were to legacy fields, tables, and layouts. I have many backups of the sullied files in various FileMaker versions, so I am relatively at ease.

                                With the recovered files, the database is running fine so far. I will let you know if FM14 clients experience any more crashes. Hopefully these reported issues were resolved with the recovery.

                                • 13. Re: FM Pro 14 - Crash - Division by zero
                                  DD_1

                                  Apologies for the late update. Even after the recovery on all files, I am still getting the same reports of crashes with FM14 client.

                                  • 14. Re: FM Pro 14 - Crash - Division by zero
                                    TSGal

                                    DD:

                                    Since Testing and Development are unable to reproduce the issue based on the dmp files, they have asked for a copy of the database file.  Send a copy/clone of the database file to the email address provided in the earlier private message.

                                    TSGal
                                    FileMaker, Inc.