~oif-team/geis/2.1.2

« back to all changes in this revision

Viewing changes to libutouch-geis/geis_attr.c

  • Committer: Stephen M. Webb
  • Date: 2011-03-17 00:00:42 UTC
  • mfrom: (115.1.10 lp-733296)
  • Revision ID: stephen.webb@canonical.com-20110317000042-3k3dl2sa4fa2yddq
Implement device enumeration (fixes LP: #733296).

Show diffs side-by-side

added added

removed removed

Lines of Context:
185
185
        break;
186
186
 
187
187
      case GEIS_ATTR_TYPE_STRING:
188
 
        attr->attr_value.s = (GeisString)attr_value;
 
188
        attr->attr_value.s = (GeisString)strdup(attr_value);
189
189
        break;
190
190
 
191
191
      default:
203
203
  {
204
204
    attr->attr_destructor(attr->attr_value.p);
205
205
  }
 
206
  else if (attr->attr_type == GEIS_ATTR_TYPE_STRING)
 
207
  {
 
208
    free((char *)attr->attr_value.s);
 
209
  }
206
210
  free((void *)attr->attr_name);
207
211
  free(attr);
208
212
}