• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Odd File Write Issue
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Odd File Write Issue


  • Subject: Odd File Write Issue
  • From: andy knasinski <email@hidden>
  • Date: Sat, 5 Dec 2009 13:13:51 -0600

We're doing some text manipulation and then writing it to disk. For one client, on an older PPC mac with 10.4.11 they are getting ASCII null characters between every character written to disk. If I look at the string being written, it's correct (no nulls) but on disk it has them.

What would cause this to happen!?

on write_to_file(this_data, target_file, append_data)
try
set the target_file to the target_file as text
set the open_target_file to ¬
open for access file target_file with write permission
if append_data is false then ¬
set eof of the open_target_file to 0
write this_data to the open_target_file starting at eof
close access the open_target_file
return true
on error
try
close access file target_file
end try
return false
end try
end write_to_file

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Odd File Write Issue
      • From: Emmanuel LEVY <email@hidden>
    • Re: Odd File Write Issue
      • From: Luther Fuller <email@hidden>
  • Prev by Date: do shell script flaw
  • Next by Date: Re: Odd File Write Issue
  • Previous by thread: Server log on script
  • Next by thread: Re: Odd File Write Issue
  • Index(es):
    • Date
    • Thread