Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 6eb2e96 in mainline for uspace/srv/fs/fat/fat_ops.c


Ignore:
Timestamp:
2009-04-10T07:53:54Z (13 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master
Children:
3cc6a52
Parents:
f4b1535
Message:

str_cpy() and str_ncpy() in userspace. Nuke strcpy() and strncpy().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/fs/fat/fat_ops.c

    rf4b1535 r6eb2e96  
    490490            str_cmp(d->name, FAT_NAME_DOT) == 0) {
    491491                memset(d, 0, sizeof(fat_dentry_t));
    492                 strcpy(d->name, FAT_NAME_DOT);
    493                 strcpy(d->ext, FAT_EXT_PAD);
     492                str_cpy(d->name, 8, FAT_NAME_DOT);
     493                str_cpy(d->ext, 3, FAT_EXT_PAD);
    494494                d->attr = FAT_ATTR_SUBDIR;
    495495                d->firstc = host2uint16_t_le(childp->firstc);
     
    500500            str_cmp(d->name, FAT_NAME_DOT_DOT) == 0) {
    501501                memset(d, 0, sizeof(fat_dentry_t));
    502                 strcpy(d->name, FAT_NAME_DOT_DOT);
    503                 strcpy(d->ext, FAT_EXT_PAD);
     502                str_cpy(d->name, 8, FAT_NAME_DOT_DOT);
     503                str_cpy(d->ext, 3, FAT_EXT_PAD);
    504504                d->attr = FAT_ATTR_SUBDIR;
    505505                d->firstc = (parentp->firstc == FAT_CLST_ROOT) ?
Note: See TracChangeset for help on using the changeset viewer.