Ignore:
Timestamp:
2010-08-18T10:56:11+12:00 (14 years ago)
Author:
mdewsnip
Message:

Now always applies dm_safe() to [srclink_file] metadata values, because these should be filenames only (that shouldn't contain macros), and we need to escape underscores in the filenames to avoid confusing the macro system.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/runtime-src/src/recpt/formattools.cpp

    r22650 r22665  
    10841084    fresh_metatext = text_html_safe;
    10851085      }
    1086       // New "dmsafe" special formatting option
    1087       if (meta.metacommand & mDMSafe)
     1086      // New "dmsafe" special formatting option (always apply to "srclink_file" metadata)
     1087      if (meta.metacommand & mDMSafe || meta.metaname == "srclink_file")
    10881088      {
    10891089    // Make it macro-safe
     
    11611161      fresh_metatext = text_html_safe;
    11621162    }
    1163     // New "dmsafe" special formatting option
    1164     if (meta.metacommand & mDMSafe)
     1163    // New "dmsafe" special formatting option (always apply to "srclink_file" metadata)
     1164    if (meta.metacommand & mDMSafe || meta.metaname == "srclink_file")
    11651165    {
    11661166      // Make it macro-safe
Note: See TracChangeset for help on using the changeset viewer.