Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 10.0.5
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      Windows

      Description

      It's not possible to free a dynamic column, since dynstr_free() is not exported. Additionally the initialization macro should have a mariadb_ prefix.

      Suggested fix:

      === modified file 'include/ma_dyncol.h'
      --- include/ma_dyncol.h 2013-01-29 14:10:47 +0000
      +++ include/ma_dyncol.h 2013-09-04 06:59:14 +0000
      @@ -181,7 +181,7 @@
       enum enum_dyncol_func_result
       mariadb_dyncol_json(DYNAMIC_COLUMN *str, DYNAMIC_STRING *json);
       
      -#define dynamic_column_initialize(A) memset((A), 0, sizeof(*(A)))
      +#define mariadb_dyncol_init(A) memset((A), 0, sizeof(*(A)))
       #define dynamic_column_column_free(V) dynstr_free(V)
       
       /* conversion of values to 3 base types */
      
      === modified file 'libmysql/CMakeLists.txt'
      --- libmysql/CMakeLists.txt     2013-07-21 14:39:19 +0000
      +++ libmysql/CMakeLists.txt     2013-09-04 06:52:40 +0000
      @@ -229,6 +229,7 @@
       mariadb_dyncol_update_many_named
       mariadb_dyncol_exists
       mariadb_dyncol_exists_named
      +mariadb_dyncol_free
       mariadb_dyncol_list
       mariadb_dyncol_list_named
       mariadb_dyncol_get
      
      === modified file 'mysys/ma_dyncol.c'
      --- mysys/ma_dyncol.c   2013-08-07 15:40:25 +0000
      +++ mysys/ma_dyncol.c   2013-09-04 06:49:57 +0000
      @@ -4324,3 +4324,13 @@
         *column_count= header.column_count;
         return rc;
       }
      +
      +/**
      +  Free dynamic column
      +
      +  @param str             The packed string
      +*/
      +void mariadb_dyncol_free(DYNAMIC_COLUMN *str)
      +{
      +  dynstr_free(str);
      +}
      

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            sanja Oleksandr Byelkin added a comment -

            above is incomplete patch. The complete patch committed 12.09.2013 09:45 EET subject of the e-mail is "[Commits] Rev 3812: MDEV-4993:Impossible to free a dynamic column in file:///home/bell/maria/bzr/work-maria-10.0-MDEV-4994/"

            Show
            sanja Oleksandr Byelkin added a comment - above is incomplete patch. The complete patch committed 12.09.2013 09:45 EET subject of the e-mail is " [Commits] Rev 3812: MDEV-4993 :Impossible to free a dynamic column in file:///home/bell/maria/bzr/work-maria-10.0-MDEV-4994/ "
            Hide
            sanja Oleksandr Byelkin added a comment -

            New patch with other functions renaming committed.

            Show
            sanja Oleksandr Byelkin added a comment - New patch with other functions renaming committed.
            Hide
            sanja Oleksandr Byelkin added a comment -

            The knowledge base information fixed.

            Show
            sanja Oleksandr Byelkin added a comment - The knowledge base information fixed.

              People

              • Assignee:
                sanja Oleksandr Byelkin
                Reporter:
                georg Georg Richter
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: