strtok returns unwanted empty line

Hi, I am tring to strip one text of all the symbols of my choice and print all the words out one by one on separate lines into another file. Every time I reach the end of the input file´s line´s end I get an empty line in the output file. Any help in understanding and fixing this is appreciated.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include <iostream>
#include <stdio.h>
#include <conio.h>
#include <string.h>


int main()
{

    FILE *fp,*fpp;
    char *pnt;
    char abi[2000];
    fp = fopen("Teaduskond.txt","r");
    fpp = fopen("Storage.txt","w");
    while(!feof(fp)){
        fgets(abi,200,fp);
        pnt = strtok(abi," ,.-/()[]\*0123456789");
        while(pnt != NULL){
            fprintf(fpp,"%s\n",pnt);
            pnt = strtok (NULL, " ,.-/()[]\*0123456789");
        }
    }
    fclose(fp);
    fclose(fpp);
    printf("\n\nVajuta suvalist klahvi...");
    getch();
    return 0;
}
I would like to ppoint out that the string literal in the statement below is invalid

pnt = strtok(abi," ,.-/()[]\*0123456789");

Symbol '\' shall be doubled.

pnt = strtok(abi," ,.-/()[]\\*0123456789");

Topic archived. No new replies allowed.