Lines Matching refs:p2
32 struct sshbuf *p1, *p2, *p3; in sshbuf_fixed() local
75 p2 = sshbuf_fromb(p1); in sshbuf_fixed()
76 ASSERT_PTR_NE(p2, NULL); in sshbuf_fixed()
79 ASSERT_PTR_EQ(sshbuf_parent(p2), p1); in sshbuf_fixed()
80 ASSERT_PTR_EQ(sshbuf_ptr(p2), sshbuf_ptr(p1)); in sshbuf_fixed()
82 ASSERT_PTR_NE(sshbuf_ptr(p2), NULL); in sshbuf_fixed()
84 ASSERT_PTR_EQ(sshbuf_mutable_ptr(p2), NULL); in sshbuf_fixed()
85 ASSERT_SIZE_T_EQ(sshbuf_len(p1), sshbuf_len(p2)); in sshbuf_fixed()
86 ASSERT_INT_EQ(sshbuf_get_u8(p2, &c), 0); in sshbuf_fixed()
87 ASSERT_PTR_EQ(sshbuf_ptr(p2), sshbuf_ptr(p1) + 1); in sshbuf_fixed()
89 ASSERT_INT_EQ(sshbuf_get_u32(p2, &i), 0); in sshbuf_fixed()
90 ASSERT_PTR_EQ(sshbuf_ptr(p2), sshbuf_ptr(p1) + 5); in sshbuf_fixed()
92 ASSERT_INT_EQ(sshbuf_get_cstring(p2, &s, &l), 0); in sshbuf_fixed()
93 ASSERT_SIZE_T_EQ(sshbuf_len(p2), 0); in sshbuf_fixed()
98 sshbuf_free(p2); in sshbuf_fixed()
108 p2 = sshbuf_new(); in sshbuf_fixed()
109 ASSERT_PTR_NE(p2, NULL); in sshbuf_fixed()
111 ASSERT_INT_EQ(sshbuf_put_stringb(p2, p1), 0); in sshbuf_fixed()
112 ASSERT_SIZE_T_EQ(sshbuf_len(p2), sizeof(test_buf) + 4 - 1); in sshbuf_fixed()
113 ASSERT_INT_EQ(sshbuf_froms(p2, &p3), 0); in sshbuf_fixed()
114 ASSERT_SIZE_T_EQ(sshbuf_len(p2), 0); in sshbuf_fixed()
120 ASSERT_INT_EQ(sshbuf_put_stringb(p2, p1), 0); in sshbuf_fixed()
121 ASSERT_INT_EQ(sshbuf_consume_end(p2, 1), 0); in sshbuf_fixed()
122 ASSERT_INT_EQ(sshbuf_froms(p2, &p3), SSH_ERR_MESSAGE_INCOMPLETE); in sshbuf_fixed()
124 sshbuf_free(p2); in sshbuf_fixed()