]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Compiler is correct... if bio is nonnull, this should be do {} while ()
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Sat, 19 Oct 2024 02:24:25 +0000 (20:24 -0600)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Sat, 19 Oct 2024 02:24:25 +0000 (20:24 -0600)
src/lib/bio/base.c

index f7c56f0eaaeb86a4ff69d631295aca9ef754af1c..09970e99542a5f0df3b665650061e2caecd845cf 100644 (file)
@@ -267,13 +267,13 @@ void fr_bio_eof(fr_bio_t *bio)
  */
 int fr_bio_write_flush(fr_bio_t *bio)
 {
-       while (bio) {
+       do {
                if (((fr_bio_common_t *) bio)->priv_cb.flush) {
                        return ((fr_bio_common_t *) bio)->priv_cb.flush(bio);
                }
 
                bio = fr_bio_next(bio);
-       }
+       } while (bio);
 
        return 1;
 }