Created By unreturnable at 2017/09/13 14:46

https://sucs.org/pb/911 (plain)
  1.   /* if the option is set, read an initial password */
  2.   rawpw[0]=0;
  3.   if (autocreate) {
  4.       char *p;
  5.       if (fgets(rawpw, sizeof rawpw, stdin) == NULL) {
  6.           printf("Expected initial password\n");
  7.           return 1;
  8.       }
  9.       if ((p=strchr(rawpw,'\r'))!=NULL) *p=0;
  10.       if ((p=strchr(rawpw,'\n'))!=NULL) *p=0;
  11.   } else {
  12.           /* read the password / session string */
  13.       char *p;
  14.       if (fgets(passwd, sizeof passwd, stdin) == NULL) {
  15.           printf("Expected password\n");
  16.           return 1;
  17.       }
  18.       if ((p=strchr(passwd,'\r'))!=NULL) *p=0;
  19.       if ((p=strchr(passwd,'\n'))!=NULL) *p=0;
  20.   }

You must be logged in to paste new items to the PasteBin