Skip to content

Commit d867411

Browse files
committed
test bug
1 parent 98147f9 commit d867411

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

jwt.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -374,11 +374,8 @@ PHP_FUNCTION(jwt_encode)
374374

375375
/* set expiration and not before */
376376
jwt_options->expiration = jwt_hash_str_find_long(claims, "exp");
377-
printf("%s\n", "1");
378377
jwt_options->not_before = jwt_hash_str_find_long(claims, "nbf");
379-
printf("%s\n", "2");
380378
jwt_options->iat = jwt_hash_str_find_long(claims, "iat");
381-
printf("%s\n", "3");
382379

383380
/* init */
384381
array_init(&header);
@@ -401,14 +398,18 @@ PHP_FUNCTION(jwt_encode)
401398
smart_str_free(&json_header);
402399
smart_str_free(&json_claims);
403400

401+
printf("%s\n", "=========");
402+
404403
/* sign */
405404
if (jwt->alg == JWT_ALG_NONE) {
406405
// alg none.
407406
smart_str_appendl(&segments, ".", 1);
407+
printf("%s\n", "++++++++++++");
408408
} else {
409409
/* set jwt struct */
410410
jwt->key = key;
411411
jwt->str = segments.s;
412+
printf("%s\n", "------------");
412413

413414
/* sign */
414415
if (jwt_sign(jwt, &sig, &sig_len)) {

0 commit comments

Comments
 (0)