bunch of ^@^@^@^@^@^@^@^@'s in bash log file

I have a bash script that has been running fine for months that scans a bunch of files and gives me a log file output, it has suddenly started putting 1.5M of a repeating sequence of ^@^@^@^@^@^@^@^@^@^@ on the first line of the logfile, is this a unicode problem I should be setting something in my bash script? I already had PATH issues after awhile of running (that I solved with your help, thanks!). Any suggestions?

Find the problem in your script and fix it.

um, thanks?

Where do you see those characters? When you look at the file using vi/vim? If so, '^@' (one character, not two) is the representation of the NULL-byte. Example of this happening is when you truncate a file while there's still an open file-handle.

It's an extremely long sequence of those 2 characters with no spaces between the 2 character pattern, only on the first line of the file when viewing with either vi or cat, it's almost like I'm not cleaning up from the last time I ran the script or something? I can't understand why it ran once a day for months and just now started doing this. The script takes >20 hours to run once.

This is usually the case in VI when the line is "too long", or? (seen it on AIX, Solaris - but tried it on Linux, and that doesn't happen somehow!)