Server IP : 104.21.38.3 / Your IP : 172.70.143.69 Web Server : Apache System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /www/server/php/74/src/ext/gd/libgd/ |
Upload File : |
#ifdef HAVE_CONFIG_H #include "config.h" #endif #include "gd.h" #include "gdhelpers.h" #include <stdlib.h> #include <string.h> /* TBB: gd_strtok_r is not portable; provide an implementation */ #define SEP_TEST (separators[*((unsigned char *) s)]) char * gd_strtok_r (char *s, char *sep, char **state) { char separators[256]; char *result = 0; memset (separators, 0, sizeof (separators)); while (*sep) { separators[*((unsigned char *) sep)] = 1; sep++; } if (!s) { /* Pick up where we left off */ s = *state; } /* 1. EOS */ if (!(*s)) { *state = s; return 0; } /* 2. Leading separators, if any */ if (SEP_TEST) { do { s++; } while (SEP_TEST); /* 2a. EOS after separators only */ if (!(*s)) { *state = s; return 0; } } /* 3. A token */ result = s; do { /* 3a. Token at end of string */ if (!(*s)) { *state = s; return result; } s++; } while (!SEP_TEST); /* 4. Terminate token and skip trailing separators */ *s = '\0'; do { s++; } while (SEP_TEST); /* 5. Return token */ *state = s; return result; }