diff options
author | Campbell Barton <campbell@blender.org> | 2022-03-24 08:33:32 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-03-24 08:54:01 +0300 |
commit | 4682a0882f02c50b20aa3c4bf9abe9f7ec2e834b (patch) | |
tree | 36dc6fb09eaa1d539e516875ed957aba5334666e /source/blender/makesrna/intern/rna_image_api.c | |
parent | 5058c4b1446f58bb9a5ddcb65f7353d9df3a594a (diff) |
Cleanup: use "filepath" instead of "filename" for full paths
Reserve "filename" when only the name component is used.
Diffstat (limited to 'source/blender/makesrna/intern/rna_image_api.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_image_api.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/makesrna/intern/rna_image_api.c b/source/blender/makesrna/intern/rna_image_api.c index 55d365f9827..0b188b2b3db 100644 --- a/source/blender/makesrna/intern/rna_image_api.c +++ b/source/blender/makesrna/intern/rna_image_api.c @@ -102,14 +102,14 @@ static void rna_Image_save(Image *image, Main *bmain, bContext *C, ReportList *r ImBuf *ibuf = BKE_image_acquire_ibuf(image, NULL, &lock); if (ibuf) { - char filename[FILE_MAX]; - BLI_strncpy(filename, image->filepath, sizeof(filename)); - BLI_path_abs(filename, ID_BLEND_PATH(bmain, &image->id)); + char filepath[FILE_MAX]; + BLI_strncpy(filepath, image->filepath, sizeof(filepath)); + BLI_path_abs(filepath, ID_BLEND_PATH(bmain, &image->id)); /* NOTE: we purposefully ignore packed files here, * developers need to explicitly write them via 'packed_files' */ - if (IMB_saveiff(ibuf, filename, ibuf->flags)) { + if (IMB_saveiff(ibuf, filepath, ibuf->flags)) { image->type = IMA_TYPE_IMAGE; if (image->source == IMA_SRC_GENERATED) { |