diff options
author | Campbell Barton <ideasman42@gmail.com> | 2017-05-19 15:18:54 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2017-05-19 15:18:54 +0300 |
commit | a7c4b6f49cf169af676a44ec2bf21ca4527fee95 (patch) | |
tree | 97b20957d5fc9ed853ba0c456da77278754cfcb7 /source/blender/imbuf | |
parent | ef549b9e556b1e4c27ae11280a672ec9be20ca11 (diff) |
Cleanup: add braces for multi-line blocks
Diffstat (limited to 'source/blender/imbuf')
-rw-r--r-- | source/blender/imbuf/intern/png.c | 3 | ||||
-rw-r--r-- | source/blender/imbuf/intern/radiance_hdr.c | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/imbuf/intern/png.c b/source/blender/imbuf/intern/png.c index 5192e3f2d26..503e63a3fb1 100644 --- a/source/blender/imbuf/intern/png.c +++ b/source/blender/imbuf/intern/png.c @@ -613,11 +613,12 @@ ImBuf *imb_loadpng(const unsigned char *mem, size_t size, int flags, char colors int unit_type; png_uint_32 xres, yres; - if (png_get_pHYs(png_ptr, info_ptr, &xres, &yres, &unit_type)) + if (png_get_pHYs(png_ptr, info_ptr, &xres, &yres, &unit_type)) { if (unit_type == PNG_RESOLUTION_METER) { ibuf->ppm[0] = xres; ibuf->ppm[1] = yres; } + } } } else { diff --git a/source/blender/imbuf/intern/radiance_hdr.c b/source/blender/imbuf/intern/radiance_hdr.c index 71e74928e20..a21468e474c 100644 --- a/source/blender/imbuf/intern/radiance_hdr.c +++ b/source/blender/imbuf/intern/radiance_hdr.c @@ -340,13 +340,14 @@ static int fwritecolrs(FILE *file, int width, int channels, unsigned char *ibufs } if (((beg - j) > 1) && ((beg - j) < MINRUN)) { c2 = j + 1; - while (rgbe_scan[c2++][i] == rgbe_scan[j][i]) + while (rgbe_scan[c2++][i] == rgbe_scan[j][i]) { if (c2 == beg) { /* short run */ putc((unsigned char)(128 + beg - j), file); putc((unsigned char)(rgbe_scan[j][i]), file); j = beg; break; } + } } while (j < beg) { /* write out non-run */ if ((c2 = beg - j) > 128) c2 = 128; |