-O nobuf: disable IO buffering
[tfcrypt.git] / tfc_misc.c
index bfb7265ff2dbf00442f26702456e7caeaf2ea864..01998f2f13a877e451fd007cfac347282a2c896d 100644 (file)
@@ -97,12 +97,21 @@ const char *tfc_modename(int mode)
                case TFC_MODE_XTS: return "XTS";
                case TFC_MODE_ECB: return "ECB";
                case TFC_MODE_CBC: return "CBC";
-               case TFC_MODE_OCB: return "OCB";
        }
 
        return NULL;
 }
 
+tfc_yesno tfc_is_freestream(int mode)
+{
+       switch (mode) {
+               case TFC_MODE_PLAIN:
+               case TFC_MODE_STREAM: return YES;
+       }
+
+       return NO;
+}
+
 void tfc_getcurtime(tfc_useconds *tx)
 {
        struct timespec t;