~ubuntu-branches/ubuntu/saucy/python-imaging/saucy-proposed

« back to all changes in this revision

Viewing changes to libImaging/Palette.c

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2013-03-20 16:44:01 UTC
  • mfrom: (2.1.13 experimental)
  • Revision ID: package-import@ubuntu.com-20130320164401-ptf6m0ttg4zw72az
Tags: 1.1.7+2.0.0-1
Pillow 2.0.0 release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
    if (!palette)
38
38
        return (ImagingPalette) ImagingError_MemoryError();
39
39
 
40
 
    strcpy(palette->mode, mode);
 
40
    strncpy(palette->mode, mode, IMAGING_MODE_LENGTH);
41
41
 
42
42
    /* Initialize to ramp */
43
43
    for (i = 0; i < 256; i++) {