Changeset 21961

Show
Ignore:
Timestamp:
27.04.2010 12:36:54 (9 years ago)
Author:
mdewsnip
Message:

Added call to reset() on the inconverter before converting each CGI argument in args_tounicode(), to prevent problems (infinite loops) when converting the last argument left the converter in a bad state.

Files:
1 modified

Legend:

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

    r18882 r21961  
    826826  while (here != end) { 
    827827    if ((*here).second.value.getencoding() > 0) { 
     828      // Call reset() before converting each argument, to prevent problems when converting the last 
     829      //   argument left the converter in a bad state 
     830      inconvert.reset(); 
    828831      (*here).second.value = inconvert.convert((*here).second.value); 
    829832    }