Skip to content
  • Karl Wette's avatar
    ComputeFstat: implement reference counting for common workspace · aa849106
    Karl Wette authored and Reinhard Prix's avatar Reinhard Prix committed
    - Gives user flexibility to free FstatInput in any order without
      problems; workspace is freed only once it's no longer needed
    - First FstatInput allocates memory for workspace and reference
      counter; subsequent FstatInput store pointers to workspace and
      reference counter, which is incremented
    - When destroyed, each FstatInput decrements reference counter;
      once it reaches 0, workspace and reference count memory are freed
    - Refs #2001
    Original: 503044dd82f5975b0cd5c6449f02d4658b561709
    aa849106