Changeset 7565
- Timestamp:
- 05/07/08 00:08:16 (2 months ago)
- Files:
-
- trunk/mapserver/HISTORY.TXT (modified) (1 diff)
- trunk/mapserver/mapshape.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/mapserver/HISTORY.TXT
r7563 r7565 13 13 Current Version (5.1-dev, SVN trunk): 14 14 ------------------------------------- 15 16 - Don't ignore .qix file when DATA reference includes .shp extension (#590) 15 17 16 18 - CGI able to alter layers with space and underscores (#2516) trunk/mapserver/mapshape.c
r7535 r7565 1719 1719 rectObj shaperect; 1720 1720 char *filename; 1721 1721 char *sourcename = 0; /* shape file source string from map file */ 1722 char *s = 0; /* pointer to start of '.shp' in source string */ 1723 1722 1724 if(shpfile->status) { 1723 1725 free(shpfile->status); … … 1737 1739 return(MS_FAILURE); 1738 1740 } 1739 for(i=0;i<shpfile->numshapes;i++) 1741 for(i=0;i<shpfile->numshapes;i++) { 1740 1742 msSetBit(shpfile->status, i, 1); 1741 } else { 1742 if((filename = (char *)malloc(strlen(shpfile->source)+strlen(MS_INDEX_EXTENSION)+1)) == NULL) { 1743 } 1744 } 1745 else { 1746 1747 /* deal with case where sourcename is of the form 'file.shp' */ 1748 sourcename = strdup(shpfile->source); 1749 s = strcasestr(sourcename, ".shp"); 1750 if( s ) *s = '\0'; 1751 1752 if((filename = (char *)malloc(strlen(sourcename)+strlen(MS_INDEX_EXTENSION)+1)) == NULL) { 1743 1753 msSetError(MS_MEMERR, NULL, "msShapefileWhichShapes()"); 1744 1754 return(MS_FAILURE); 1745 1755 } 1746 sprintf(filename, "%s%s", shpfile->source, MS_INDEX_EXTENSION); 1756 1757 sprintf(filename, "%s%s", sourcename, MS_INDEX_EXTENSION); 1747 1758 1748 1759 shpfile->status = msSearchDiskTree(filename, rect, debug); 1749 1760 free(filename); 1761 free(sourcename); 1750 1762 1751 1763 if(shpfile->status) { /* index */
