Changeset 223bc6472936d8761b4397a20496e914b5cb5982 for src/modules
- Timestamp:
- 07/03/08 23:43:01 (2 months ago)
- git-parent:
- Files:
-
- src/modules/cache.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
src/modules/cache.c
re21ba63 r223bc64 179 179 } 180 180 181 #ifdef DISTRO_VERSION 182 /* Check for distribution specific version */ 183 char p_distrostring[sizeof( DISTRO_VERSION )]; 184 i_size = sizeof( DISTRO_VERSION ) - 1; 185 i_read = fread( p_distrostring, 1, i_size, file ); 186 if( i_read != i_size || 187 memcmp( p_distrostring, DISTRO_VERSION, i_size ) ) 188 { 189 msg_Warn( p_this, "This doesn't look like a valid plugins cache" ); 190 fclose( file ); 191 return; 192 } 193 #endif 194 181 195 /* Check Sub-version number */ 182 196 i_read = fread( &i_marker, 1, sizeof(i_marker), file ); … … 497 511 if (fputs ("cache "COPYRIGHT_MESSAGE, file) == EOF) 498 512 goto error; 499 513 #ifdef DISTRO_VERSION 514 /* Allow binary maintaner to pass a string to detect new binary version*/ 515 if (fputs( DISTRO_VERSION, file ) == EOF) 516 goto error; 517 #endif 500 518 /* Sub-version number (to avoid breakage in the dev version when cache 501 519 * structure changes) */
