Uploaded image for project: 'VCL'
  1. VCL
  2. VCL-541

Remove "return 0" from all subroutines which normally return an array or hash

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.2.1
    • 2.3
    • vcld (backend)
    • None

    Description

      Subroutines which return a hash or array should not return 0 if an error occurs. For example, if the caller assumes a hash is returned and then attempts to iterate over the hash, the following error will occur:

      Can't use string ("0") as a HASH ref while "strict refs" in use at /usr/local/vcl/bin/../lib/VCL/Module/OS/Windows.pm line 1992

      Attachments

        Activity

          People

            arkurth Andrew Kurth
            arkurth Andrew Kurth
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: