- gint i;
- g_return_if_fail(d);
- g_return_if_fail(G_IS_PSPPIRE_DICT(d));
-
-
- /* Invalidate the cache from IDX onwards */
- for ( i = idx ; i < d->cache_size ; ++i )
- {
- g_free(d->variables[i]);
- d->variables[i] = 0;
- }
-
- /* Ensure that the cache is large enough */
- if ( dict_get_var_cnt(d->dict) >= d->cache_size )
- {
- d->variables = g_realloc(d->variables, sizeof(struct PsppireVariable*) *
- (d->cache_size + CACHE_CHUNK));
- d->cache_size += CACHE_CHUNK;
- }