bug in xaccFreqSpecGetFreqStr (?)
Josh Sled
jsled@asynchronous.org
Thu, 20 Sep 2001 22:02:28 -0700
On Fri, Sep 21, 2001 at 01:02:57PM +1000, Robert Graham Merkel wrote:
| On Fri, 21 Sep 2001 12:35:39 Robert Graham Merkel wrote:
| > I've just found a bug in the "SX from real trans" dialog. Create a
| > scheduled transaction of
| > "weekly" freqency using the schedule button, then try to view that
| > transaction in the Scheduled
| > Transactions list. Instant segfault.
| >
| > The problem seems to be that xaccFreqSpecGetFreqStr is looking for a
| > composite freqspec, when
| > we've got a weekly one. Why?
| >
|
| Sorry to reply to my own message, but it seems that when the full-blown
| sx editor sets a weekly SX, it creates a composite freqspec and goes
| through
| all sorts of gyrations. . . Josh, could you explain the rationale here?
A 'weekly' FreqSpec stores a single day of the week. Therefore, to create
a [single- or] multi-day weekly SX, we create a Composite FreqSpec which
contains 'N' weekly FreqSpecs [one of ea. DOW selected by the user].
I guess that assumption is implicit in the GetFreqStr code, but the
"SX from real trans" dialog sets it up with a single weekly freqspec...
the fix would be to make the SX-from-real code create a "proper" weekly
FreqSpec, and to remove/make visible that assumption/paradigm [a weekly
is really a composite of weeklyies].
...jsled