skip the readbraw tests if the server does not support it
[sfrench/samba-autobuild/.git] / source4 / torture / raw / read.c
index 977ac6b8cb5e0f6732ee1761ccaba646261f5e72..4fd2cf50c6a6b307b30f20fe3db03f1dd3798aaf 100644 (file)
@@ -622,6 +622,11 @@ static bool test_readbraw(struct torture_context *tctx,
        const char *test_data = "TEST DATA";
        uint_t seed = time(NULL);
 
+       if (!cli->transport->negotiate.readbraw_supported) {
+               printf("Server does not support readbraw - skipping\n");
+               return true;
+       }
+
        buf = talloc_zero_array(tctx, uint8_t, maxsize);
 
        if (!torture_setup_dir(cli, BASEDIR)) {