[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [VAR_NAME_LEN 00/17] Eliminate uses of VAR_NAME_LEN

From: John Darrington
Subject: Re: [VAR_NAME_LEN 00/17] Eliminate uses of VAR_NAME_LEN
Date: Tue, 8 Feb 2011 20:10:03 +0000
User-agent: Mutt/1.5.18 (2008-05-17)

There are a number of places where sprintf is used.  Using snprintf instead
might be safer. Otherwise I don't see any problem with these patches.
On Sat, Feb 05, 2011 at 01:25:42PM -0800, Ben Pfaff wrote:
     This series eliminates most uses of VAR_NAME_LEN in PSPP.  Most uses of
     VAR_NAME_LEN within PSPP are wrong due to encoding issues: the limit
     applies to variable names in the encoding used by the data set, but most
     uses of VAR_NAME_LEN actually limit the length of a name in UTF-8.  The
     UTF-8 representation of a name can be longer or shorter than its
     representation in the data set encoding, so it seems best to eliminate
     references to VAR_NAME_LEN entirely.
     Ben Pfaff (17):
       dict: Make dict_make_unique_var_name() return an allocated string.
       variable: Remove VAR_NAME_LEN limit for internal representation of
       vector: Remove VAR_NAME_LEN limit for internal representation of
       combine-files: Eliminate VAR_NAME_LEN restriction from
       FILE HANDLE: Get rid of VAR_NAME_LEN limit on handle name.
       GET DATA /TYPE=TXT: Get rid of VAR_NAME_LEN limit on variable names.
       MODIFY VARIABLES: Eliminate VAR_NAME_LEN limit on variable names.
       VECTOR: Eliminate VAR_NAME_LEN limit for variable names.
       DEBUG EVALUATE: Eliminate VAR_NAME_LEN limit.
       variable-parser: Rewrite parse_DATA_LIST_vars().
       variable-parser: Drop VAR_NAME_LEN restriction from
       DESCRIPTIVES: Eliminate main restriction on Z-score variable name
       FLIP: Eliminate false dependency on VAR_NAME_LEN.
       REGRESSION: Eliminate restriction to VAR_NAME_LEN in reg_get_name().
       text-data-import-dialog: Eliminate VAR_NAME_LEN restriction.
       por-file-reader: Remove dependency on VAR_NAME_LEN.
      src/data/dictionary.c                      |   52 ++++----
      src/data/dictionary.h                      |    7 +-
      src/data/gnumeric-reader.c                 |   13 +--
      src/data/por-file-reader.c                 |   17 +--
      src/data/psql-reader.c                     |   13 +-
      src/data/variable.c                        |    9 +-
      src/data/vector.c                          |   21 ++--
      src/language/data-io/combine-files.c       |   37 +++--
      src/language/data-io/file-handle.q         |   25 ++--
      src/language/data-io/get-data.c            |   12 +-
      src/language/dictionary/attributes.c       |   48 +++++--
      src/language/dictionary/modify-variables.c |    8 +-
      src/language/dictionary/vector.c           |   12 +-
      src/language/expressions/evaluate.c        |   11 +-
      src/language/lexer/variable-parser.c       |  208 
      src/language/stats/descriptives.c          |   77 ++++++-----
      src/language/stats/flip.c                  |    4 +-
      src/language/stats/regression.q            |   45 +++----
      src/ui/gui/text-data-import-dialog.c       |   49 ++++---
      19 files changed, 365 insertions(+), 303 deletions(-)
     pspp-dev mailing list

PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See or any PGP keyserver for public key.

Attachment: signature.asc
Description: Digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]