Skip to content
Snippets Groups Projects
Commit 4b7700d5 authored by deuce's avatar deuce
Browse files

Fix up the registration stuff. Just need to enter the "Registered To"

parent 2543b3eb
No related branches found
No related tags found
No related merge requests found
#include <stdio.h>
#include <ciolib.h>
#ifdef TODO_HEADERS
#include <dos.h>
#endif
int c_break(void){
return (1);
}
void
main(void)
{
int x = 0;
char stringz[2];
directvideo = 0;
#ifdef TODO_DOSWRAP
ctrlbrk(c_break);
#endif
textcolor(15);
cprintf("\n\rSmurf crack courtesy of [JuSTice]\n\r");
textcolor(7);
cprintf("Enter name to register under: ");
do {
gets(stringz);
} while (x == 0);
}
......@@ -29,8 +29,11 @@ __REG__main(void)
char code[40], name[80], cod;
FILE *stream;
printf("\n\r");
#if TODO_REGISTRATION
printf("Enter Registration Code: ");
gets(code);
#endif
printf("Enter Registration Name: ");
gets(name);
/* printf("Enter Intermediate Code: "); cin >> name[0];cod=atoi(name[0]);
......@@ -39,7 +42,9 @@ __REG__main(void)
* if(cod>1)for(cyc=1;cyc<cod;cyc++) fprintf(stream," %s",name[cyc]); */
stream = fopen("smurfreg.nfo", "w+");
fprintf(stream, "%s", name);
#if TODO_REGISTRATION
fprintf(stream, "\n\r%s\n\r", code);
#endif
fclose(stream);
}
......@@ -103,7 +108,12 @@ checkkey(void)
fgets(registered_name, 200, fp); /* read name from file */
if (registered_name[strlen(registered_name) - 1] == '\n')
registered_name[strlen(registered_name) - 1] = '\0';
if (registered_name[strlen(registered_name) - 1] == '\r')
registered_name[strlen(registered_name) - 1] = '\0';
if (registered_name[strlen(registered_name) - 1] == '\n')
registered_name[strlen(registered_name) - 1] = '\0';
#if TODO_REGISTRATION
fscanf(fp, "%lu", &supplied_key); /* read key from file */
fclose(fp); /* Close file */
......@@ -116,6 +126,9 @@ checkkey(void)
registeredxx = 1; /* Then switch program into registered
* mode */
}
#else
registeredxx = 1;
#endif
}
if (registeredxx == 1)
statis = 1; /* If registered mode */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment